Skip to content

Commit

Permalink
feat: Added script converting public key pem file to public key hex
Browse files Browse the repository at this point in the history
  • Loading branch information
orlowskilp committed Jun 25, 2024
1 parent 3e85aeb commit 558a83c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions pem2pubhex.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash

cat $1 | head -3 | tail -2 | base64 --decode | xxd -c 0 -ps | tail -c 129
2 changes: 1 addition & 1 deletion pubhex2evm.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
#!/bin/bash

echo 0x$(cat $1 | keccak-256sum -x -l | tr -d ' -' | tail -c 41)
cat $1 | keccak-256sum -x -l | tr -d ' -' | tail -c 41 | xargs -I % echo 0x%

0 comments on commit 558a83c

Please sign in to comment.