mirror of
https://github.com/sonr-io/sonr.git
synced 2026-08-02 17:31:39 +00:00
feature/dwn sw js (#1103)
- **feat(macaroon): add and to macaroon genesis** - **refactor: move schema definitions to dedicated file** - **feat: remove Session model** - **refactor: move session middleware to internal package**
This commit is contained in:
@@ -32,16 +32,16 @@ message Params {
|
||||
message Methods {
|
||||
option (amino.name) = "macaroon/methods";
|
||||
option (gogoproto.equal) = true;
|
||||
|
||||
repeated string methods = 1;
|
||||
string default = 1;
|
||||
repeated string supported = 2;
|
||||
}
|
||||
|
||||
// Scopes defines the set of scopes
|
||||
message Scopes {
|
||||
option (amino.name) = "macaroon/scopes";
|
||||
option (gogoproto.equal) = true;
|
||||
|
||||
repeated string scopes = 1;
|
||||
string base = 1;
|
||||
repeated string supported = 2;
|
||||
}
|
||||
|
||||
// Caveats defines the available caveats
|
||||
@@ -49,5 +49,6 @@ message Caveats {
|
||||
option (amino.name) = "macaroon/caveat";
|
||||
option (gogoproto.equal) = true;
|
||||
|
||||
repeated string caveats = 1;
|
||||
repeated string supported_first_party = 1;
|
||||
repeated string supported_third_party = 2;
|
||||
}
|
||||
|
||||
@@ -27,3 +27,25 @@ message Grant {
|
||||
string origin = 4;
|
||||
int64 expiry_height = 5;
|
||||
}
|
||||
|
||||
message Macaroon {
|
||||
option (cosmos.orm.v1.table) = {
|
||||
id: 1
|
||||
primary_key: {
|
||||
fields: "id"
|
||||
auto_increment: true
|
||||
}
|
||||
index: {
|
||||
id: 1
|
||||
fields: "subject,origin"
|
||||
unique: true
|
||||
}
|
||||
};
|
||||
|
||||
uint64 id = 1;
|
||||
string controller = 2;
|
||||
string subject = 3;
|
||||
string origin = 4;
|
||||
int64 expiry_height = 5;
|
||||
string macaroon = 6;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user