Repository navigation
Conversation
The `SimplePolicy` default `min_feerate_per_kw` of 253 sat/kw comes from stacks where the signer builds its own sweeps. In Greenlight the transactions gated by this check are built by CLN: lightningd and onchaind derive the sweep feerate from their own backend-backed estimates and apply their own floors and worth-it checks before ever requesting a signature. During quiet-fee periods CLN's estimates fall below 253 sat/kw, and the signer then hard-fails `SIGN_PENALTY_TO_US` with 'policy failure: validate_justice_sweep: validate_sweep: validate_fee: feerate below minimum: 226 < 253', leaving justice sweeps unsigned until feerates recover. Since CLN will not produce sweeps anywhere near this range under normal conditions, the default floor contradicts CLN's fee policy rather than protecting against it. Set `min_feerate_per_kw` to 75 sat/kw (~0.3 sat/vB): low enough to never second-guess a CLN-built sweep, yet still a sanity check that rejects zero-fee or absurdly low transactions.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Since the VLS 1.0.0-rc.1 upgrade (
6eed32f5),SIGN_PENALTY_TO_USgoes throughvalidate_justice_sweep -> validate_sweep -> validate_fee, which compares the sweep tx feerate againstSimplePolicy::min_feerate_per_kw— 253 sat/kw (~1 sat/vB) frommake_default_simple_policy.In Greenlight those transactions are built by CLN (lightningd/onchaind), which derives the sweep feerate from its own backend-backed estimates and applies its own floors and worth-it checks before requesting the signature. During quiet-fee periods the estimate drops below 253 sat/kw and the signer hard-fails the signature, e.g. seen in production today:
The justice sweep then stays unsigned until network feerates recover — the signer's floor contradicts CLN's fee policy instead of protecting against it.
Fix
Set
policy.min_feerate_per_kw = 75(~0.3 sat/vB) in the gl-client signer setup: low enough to never second-guess a CLN-built sweep, while still rejecting zero-fee or absurdly low transactions.Notes
Test
cargo check -p gl-clientpasses. End-to-end: attach a local signer to a node with a pending justice sweep at low feerate and observe the sweep tx now gets signed and broadcast instead of a FailedPrecondition.