-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Closed
Description
Summary
POST body is not validated because it doesn't use BaseReq nor the StdTx.ValidateBasic()
Problem Definition
We are using SignBody for POST tx/sign but the StdTx is not validated at any point of the request.
cosmos-sdk/x/auth/client/rest/sign.go
Lines 15 to 24 in c9ef680
| // SignBody defines the properties of a sign request's body. | |
| type SignBody struct { | |
| Tx auth.StdTx `json:"tx"` | |
| LocalAccountName string `json:"name"` | |
| Password string `json:"password"` | |
| ChainID string `json:"chain_id"` | |
| AccountNumber uint64 `json:"account_number"` | |
| Sequence uint64 `json:"sequence"` | |
| AppendSig bool `json:"append_sig"` | |
| } |
Proposal
Use BaseReq with its validation function and use StdTx.Validate() to validate the transaction.
For Admin Use
- Not duplicate issue
- Appropriate labels applied
- Appropriate contributors tagged
- Contributor assigned/self-assigned
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels