-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
bank.SendKeeper breaks intended least authority permissioning #2887
Comments
We'd need this for IBC, correct? I think my vote would be to remove it and possibly create a new IBC bank keeper which the IBC module uses? |
There already is such as keeper - |
I mean |
I see, sure; let's wait to see exactly what the IBC module needs to do first though. |
…istency * Update PENDING.md * New structure * Start transactions section * Remove MsgIssue * Update keepers.md * Add state.md * Update keepers.md, discovered #2887 * Move inputOutputCoins to BaseKeeper * Remove no-loner-applicable tests * More spec updates * Tiny cleanup * Clarify storage rationale * Warn the user * Remove extra newline
…istency * Update PENDING.md * New structure * Start transactions section * Remove MsgIssue * Update keepers.md * Add state.md * Update keepers.md, discovered #2887 * Move inputOutputCoins to BaseKeeper * Remove no-loner-applicable tests * More spec updates * Tiny cleanup * Clarify storage rationale * Warn the user * Remove extra newline
bank.SendKeeper
is intended only to allow transfers of coins between accounts, but in fact it allows arbitrary minting or burning of coins withkeeper.inputOutputCoins
, because the invariantinputs.Sum() == outputs.Sum()
is only checked inValidateBasic()
onbank.MsgSend
. Modules which are passed abank.SendKeeper
have just as much power as modules which are passed the fullbank.BaseKeeper
.Recommended mitigation: remove
inputOutputCoins
from thesendKeeper
(it isn't used in any other modules presently).Alternative mitigation: repeat the necessary validation, which is very inexpensive, in the keeper.
The text was updated successfully, but these errors were encountered: