Skip to content

Commit

Permalink
tests: Check decode with high bits set fails
Browse files Browse the repository at this point in the history
This doesn't catch out-of-bounds memory access, but it's a good test to have anyway.
  • Loading branch information
luke-jr committed Feb 28, 2015
1 parent b6adca8 commit cdeed07
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/decode-highbit-prefix.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/sh
hex=$(echo 993233 | xxd -r -p | base58 -d 25 || echo FAIL)
test "x${hex}" = "xFAIL"
3 changes: 3 additions & 0 deletions tests/decode-highbit.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/sh
hex=$(echo 319932 | xxd -r -p | base58 -d 25 || echo FAIL)
test "x${hex}" = "xFAIL"

0 comments on commit cdeed07

Please sign in to comment.