From 876e01e16cc04824b23ce9f35dbfd88b0223e452 Mon Sep 17 00:00:00 2001 From: Patrick Lodder Date: Sat, 17 Oct 2015 13:30:23 +0200 Subject: [PATCH] Make low-s verification mandatory for standard script verification 1.8.3 backport This change makes a node only accept transactions with low-s signature encoding for relay and mining, but allows transactions with high-s signature encoding in mined blocks (no blocks will be rejected) --- src/script.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/script.h b/src/script.h index 0d8a8544b..99724f895 100644 --- a/src/script.h +++ b/src/script.h @@ -207,7 +207,8 @@ static const unsigned int MANDATORY_SCRIPT_VERIFY_FLAGS = SCRIPT_VERIFY_P2SH; // blocks and we must accept those blocks. static const unsigned int STANDARD_SCRIPT_VERIFY_FLAGS = MANDATORY_SCRIPT_VERIFY_FLAGS | SCRIPT_VERIFY_STRICTENC | - SCRIPT_VERIFY_NULLDUMMY; + SCRIPT_VERIFY_NULLDUMMY | + SCRIPT_VERIFY_LOW_S; // For convenience, standard but not mandatory verify flags. static const unsigned int STANDARD_NOT_MANDATORY_VERIFY_FLAGS = STANDARD_SCRIPT_VERIFY_FLAGS & ~MANDATORY_SCRIPT_VERIFY_FLAGS;