Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Contract creation function has no confirmation checking #12

Open
joshuahannan opened this issue Apr 25, 2018 · 0 comments
Open

Contract creation function has no confirmation checking #12

joshuahannan opened this issue Apr 25, 2018 · 0 comments

Comments

@joshuahannan
Copy link

The wallet library has the ability to create contracts if serveTx is called with a null _to address. Contract creation in that case is delegated to the helper function createContract. This function is exposed as public, but it does not require confirmations like the rest of the external interface of WalletMainLib. This may be misleading to a developer, who might accidentally expose createContract in the external interface of a contract thinking it functions like the rest of the wallet’s interface. This function being public would allow extraction of funds by any caller.
Consider changing createContract’s visibility to private, so that it can only be invoked by the interface exposed by WalletMainLib, particularly serveTx.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant