UWAVM is a WebAssembly VM in Go. UWAVM provide tools to decode wasm binary files that compiled by golang, javascript, c/c++, rust.
- Go 1.12.x or later
- Clone the repository
git clone https://github.com/BeDreamCoder/uwavm.git
- Build uwavm executable program
make build
cd output
- Golang contract
./uwavm contract deploy -n erc20 -l go -a '{"totalSupply":"1000000"}' -p ../testdata/erc20_go.wasm -c alice
./uwavm contract query -n erc20 -l go -m query -a '{"action":"balanceOf","address":"alice"}' -c alice
./uwavm contract invoke -n erc20 -l go -m invoke -a '{"action":"transfer","to":"bob","amount":"100"}' -c alice
- C++ contract
./uwavm contract deploy -n erc20 -l c -a '{"totalSupply":"1000000"}' -p ../testdata/erc20_c.wasm -c alice
./uwavm contract query -n erc20 -l c -m balance -a '{"caller":"alice"}' -c alice
./uwavm contract invoke -n erc20 -l c -m transfer -a '{"from":"alice","to":"bob","amount":"100"}' -c alice