Script: fixes pubKeyInput and adds a test
network: always use lowercase