cleos set account permission MYACCOUNT active '{"threshold": 1, "keys":[], "accounts":[{"permission":{"actor":"eosio.null","permission":"active"},{"permission":{"actor":"MYACCOUNT","permission":"eosio.code"},"weight":1}], "waits":[] }' owner -p MYACCOUNT cleos set account permission MYACCOUNT owner '{"threshold": 1, "keys":[], "accounts":[{"permission":{"actor":"eosio.null","permission":"owner"},{"permission":{"actor":"MYACCOUNT","permission":"eosio.code"},"weight":1}], "waits":[] }' -p MYACCOUNT Some additional points: 1. The permissions *must* be given in alphabetical order (of account name), so I am assuming that your account name would come alphabetically after `eosio.null`. If that isn't true, then you have to rearrange the permissions such that it is alphabetically correct. 2. Be aware, that the `eosio.code` permission can be used to authorise any action that the permission could normally achieve. This means that it can be used to change the keys within the contract itself. Assuming the point of nulling the keys is to make the contract immutable and provide confidence in the contract, then you will have to make it open source so that people can see that you haven't snuck a function in there that will be called at some point and change the keys so you can regain access.