Questions tagged [miniscript]
Miniscript is a structured representation of Bitcoin script which allows wallets to be more dynamic about the scripts they use.
27
questions
1
vote
2
answers
39
views
What Policy does the Liana wallet use? Why would I use this Policy?
I was looking at Wizardsardine's Liana wallet repo (beta software).
What is the Policy and associated Miniscript that is used by this wallet?
Why would I use this Policy? What is fixed and what is ...
4
votes
1
answer
212
views
When is a Miniscript solution malleable?
I'm having some trouble understanding malleability in miniscript. Specifically I cannot get why some solutions can be used instead of other.
I think using an example may help.
Say, for instance, this ...
5
votes
1
answer
125
views
How do I set up a time-decay multisig?
I want to set up a multisig that requires fewer signatures as time goes by.
Let T be some time in the future (e.g. a year from now).
Before T, 2/3 signatures are required to unlock the UTXO (send ...
1
vote
2
answers
84
views
how to open the miniscript designer?
I've read Bitcoin Core 24 brings a miniscript visual programmer. Had a look, didn't find it.
Is that true?
How to check it out?
1
vote
1
answer
47
views
Why has the Miniscript for this particular Policy changed over the past few months?
The "A 3-of-3 that turns into a 2-of-3 after 90 days" policy:
thresh(3,pk(key_1),pk(key_2),pk(key_3),older(12960))
compiled to this Miniscript a few months ago:
thresh(3,pk(key_1),s:pk(key_2)...
3
votes
2
answers
242
views
Why isn't it possible to add an OP_RETURN (or some arbitrary script) inside a taproot script path with a descriptor?
I'm reading the Bitcoin Core's descriptor documentation and I noticed that the raw() SCRIPT expression can only be used at descriptor top-level. Indeed when called with this descriptor ...
1
vote
1
answer
71
views
What is a sane Miniscript? How does it differ to a valid Miniscript?
What is a sane Miniscript? How does it differ to a valid Miniscript?
This was asked during a Bitcoin Core PR review club on Miniscript hosted by stickies-v on May 18th 2022.
4
votes
1
answer
213
views
Which wallets or libraries besides core support (or will support) P2TR descriptors?
I want to help test the WIP Bitcoin Dev Kit "Add support for Taproot and tr() descriptors", PR #593 against other implementations besides Bitcoin Core (already testing again Core 22.0). In ...
1
vote
2
answers
131
views
How would one turn a Miniscript tree into a Taproot tree with Taproot'd Miniscript?
How would one turn a Miniscript "tree" into a Taproot tree with Taproot'd Miniscript?
(To be clear unlike a Taproot tree a Miniscript tree likely would't be surfaced to the user. Breaking ...
2
votes
0
answers
26
views
Simplicity vs Miniscript [duplicate]
It is clear that both simplicity and Miniscript aims to extend and improve upon the bitcoin script. However what are the differences between them and the pros and cons they both have against the other?...
0
votes
1
answer
32
views
What is the difference between semantic policy and concrete policy in a Miniscript context?
What is the difference between semantic policy and concrete policy in a Miniscript context?
The difference between Policy and Miniscript is defined here.
0
votes
1
answer
60
views
What is a Miniscript fragment? And what should I call the underscore letter?
An example Miniscript is:
and_v(or_c(pk(B),or_c(pk(C),v:older(1000))),pk(A))
(Generated using this Miniscript site).
What would a fragment be here? What should I call the underscore letter (_v)? And ...
1
vote
2
answers
231
views
Loops in bitcoin scripting
According to this Q&A there are no loops in bitcoin script: The Bitcoin scripting system is purposefully not Turing-complete - why?
I was reading the comments in a reddit post and realized few for ...
2
votes
1
answer
166
views
Can output descriptors be used to encode any Miniscript expression?
Output descriptors provide a standard to make address bodies more exchangeable between various wallet implementations. It seems that an output descriptor can be used to encode any Miniscript ...
1
vote
1
answer
118
views
Is there anything specific to the design of the Sapio language that makes it well suited to writing covenant scripts?
I think I understand at a high level the goals of both CheckTemplateVerify (CTV, BIP 119) and the Sapio language.
Is there anything specific to the design of the Sapio language that makes it well ...
1
vote
1
answer
144
views
Difference and resources for Miniscript and Simplicity?
I have read about that it is a language for writing Bitcoin Scripts in a structured way, enabling analysis, composition, generic signing and more.
http://bitcoin.sipa.be/miniscript/ is helpful but ...
1
vote
0
answers
63
views
Bitcoin Script - Beautify
My question is if something exists to do the job in the opposite direction of miniscript.
Miniscript's intention is to help:
...writing (a subset of) Bitcoin Scripts in a structured way, enabling ...
1
vote
1
answer
82
views
Miniscript or_i, d: - do they always imply a witness input?
The question: is the following description of the behavior of these fragments correct?
The or_i fragment and d: wrappers all have an IF in their script that does not take the value from the argument(s)...
0
votes
1
answer
32
views
and(older(10),pk(A)) malleable if top-level, can it be top-level? EDIT: not malleable, was mistaken
$ ./miniscript
and(older(10),pk(A))
X 110.0000000000 37 and_v(v:pk(A),older(10)) and(older(10),pk(A))
and_v(v:pk(A),older(10))
1 scriptlen=37 maxops=2 type=B safe=yes nonmal=yes dissat=...
3
votes
1
answer
63
views
How do I write a script such that my funds are locked in a 2-of-2 multisig that converts into a 1-of-2 multisig after 365 days?
I would like my Bitcoin to have the extra security that a 2-of-2 multisig provides. With a single sig I am worried that if a single key gets hacked I will lose my funds. However, with a 2-of-2 ...
2
votes
1
answer
95
views
What is the relationship between the Minsc language and Policy language?
Quoting from the Minsc website "Minsc is a high-level scripting language...based on the Miniscript Policy language with additional features and syntactic sugar sprinkled on top including ...
3
votes
1
answer
76
views
Should the Policy to Miniscript compiler(s) be considered as deterministic and is this the end goal?
Should the Policy to Miniscript compiler(s) be considered as deterministic and is this the end goal?
This question was asked by Jeremy Rubin on ##miniscript on IRC and has been paraphrased.
For basic ...
8
votes
1
answer
305
views
In theory could we skip the proposed Taproot soft fork, activate Simplicity instead and use Simplicity to write the equivalent of Taproot scripts?
In theory could we skip the proposed Taproot soft fork, activate Simplicity instead and use Simplicity to write the equivalent of Taproot scripts? Or does Simplicity need more development and ...
3
votes
1
answer
85
views
With Miniscript why is it not possible to invert conditions with something like not()?
This question was asked by Luke Childs (@lukechilds) on Twitter.
In Miniscript would it be possible to invert conditions with something like not()? Could you essentially create a younger() out of not(...
4
votes
1
answer
156
views
Where can I find the miniscript policy language specification?
I would like to understand how miniscript works by coding it myself. As I started studying it, I realized that miniscript is more or less a 1-for-1 abstraction of a subset of Script and that the ...
15
votes
3
answers
1k
views
What does Bitcoin policy language offer the developer that Miniscript doesn't? What is the difference between Bitcoin policy language and Miniscript?
I understand that policy language compiles to Miniscript and Miniscript is encoded (correction) to Bitcoin Script. This is also a great resource on Miniscript: http://bitcoin.sipa.be/miniscript/ But I ...
6
votes
3
answers
405
views
Multisig where one of the keys specifically is required?
Is it possible to make a multisig wallet that requires one of the keys specifically and any of the other ones in order to sign a transaction?
For example, let's say I have a 2-of-3 multisig that has ...