Extract ECDSASignature.isCanonical()…

…which checks for BIP62 low S value. Adds a test.