Skip to content

Instantly share code, notes, and snippets.

View Davidson-Souza's full-sized avatar

Davidson Souza Davidson-Souza

View GitHub Profile
@storopoli
storopoli / init.lua
Last active May 19, 2026 13:33
Very Very Very Minimal init.lua
vim.pack.add{
'https://github.com/ibhagwan/fzf-lua',
'https://github.com/neovim/nvim-lspconfig',
}
-- LSP
vim.o.autocomplete = true
vim.o.completeopt = 'menu,menuone,noselect,nearest'
vim.diagnostic.config({ virtual_text = false, virtual_lines = { current_line = true } })
vim.api.nvim_create_autocmd("LspAttach", {
@RobinLinus
RobinLinus / covenants_cat_ecdsa.md
Last active January 30, 2025 12:44
Emulate covenants using only OP_CAT and ECDSA signatures

Covenants with CAT and ECDSA

In his article, CAT and Schnorr Tricks I, Andrew Poelstra showed how to emulate OP_CHECKSIGFROMSTACK-like covenants using only OP_CATand Schnorr signatures.

Here, we show that a similar trick is possible to emulate covenants using only OP_CAT and ECDSA signatures.

The High-Level Idea

Recall the ECDSA Signature Equation

@RobinLinus
RobinLinus / modified-secret-sharing.py
Last active August 9, 2023 17:07
A variation of Shamir's t-of-n Secret Sharing scheme, which allows to use any given values as secret shares
#
# A variation of Shamir's t-of-n Secret Sharing scheme,
# which allows to use any `n` values as secret shares
# at the expense of having to store `(n-t)` many public shares.
# This overcomes a drawback of the orginal scheme,
# which requires to use the secret shares resulting from the scheme.
#
# For example, for a 3-of-5 this requires to store 2 public points.
#
@nickfarrow
nickfarrow / malleablefrost.md
Last active November 26, 2024 01:22
Modifying FROST Threshold and Signers

Modifying FROST Signers and Threshold

FROST's distributed key generation involves N parties each creating a secret polynomial, and sharing evaluations of this polynomial with other parties to create a distributed FROST key.

The final FROST key is described by a joint polynomial, where the x=0 intercept is the jointly shared secret s=f(0). Each participant controls a single point on this polynomial at their participant index.

The degree T-1 of the polynomials determines the threshold T of the multisignature - as this sets the number of points required to interpolate the joint polynomial and compute evaluations under the joint secret.

T parties can interact in order to interpolate evaluations using the secret f[0] without ever actually reconstructing this secret in isolation (unlike Shamir Secret Sharing where you have to reconstruct the secret).