Skip to content

Commit

Permalink
*: clarify expirations, fix #253
Browse files Browse the repository at this point in the history
This is the way it is now, just improving the documentation.

Signed-off-by: Roman Khimov <[email protected]>
  • Loading branch information
roman-khimov committed Dec 26, 2024
1 parent a55e10e commit 7523e27
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 10 deletions.
4 changes: 2 additions & 2 deletions acl/types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -226,10 +226,10 @@ message BearerToken {
// Lifetime parameters of the token. Field names taken from
// [rfc7519](https://tools.ietf.org/html/rfc7519).
message TokenLifetime {
// Expiration Epoch
// Expiration epoch, the last epoch when token is valid.
uint64 exp = 1 [json_name = "exp"];

// Not valid before Epoch
// Not valid before epoch, the first epoch when token is valid.
uint64 nbf = 2 [json_name = "nbf"];

// Issued at Epoch
Expand Down
3 changes: 2 additions & 1 deletion object/types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,8 @@ message Header {
// that affect system behaviour:
//
// * __NEOFS__EXPIRATION_EPOCH \
// Tells GC to delete object after that epoch
// Tells GC to delete object after that epoch (but object is available
// throughout the epoch specified in this attribute).
// * __NEOFS__TICK_EPOCH \
// Decimal number that defines what epoch must produce
// object notification with UTF-8 object address in a
Expand Down
4 changes: 2 additions & 2 deletions proto-docs/acl.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ Lifetime parameters of the token. Field names taken from

| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| exp | [uint64](#uint64) | | Expiration Epoch |
| nbf | [uint64](#uint64) | | Not valid before Epoch |
| exp | [uint64](#uint64) | | Expiration epoch, the last epoch when token is valid. |
| nbf | [uint64](#uint64) | | Not valid before epoch, the first epoch when token is valid. |
| iat | [uint64](#uint64) | | Issued at Epoch |


Expand Down
3 changes: 2 additions & 1 deletion proto-docs/object.md
Original file line number Diff line number Diff line change
Expand Up @@ -926,7 +926,8 @@ There are some "well-known" attributes starting with `__NEOFS__` prefix
that affect system behaviour:

* __NEOFS__EXPIRATION_EPOCH \
Tells GC to delete object after that epoch
Tells GC to delete object after that epoch (but object is available
throughout the epoch specified in this attribute).
* __NEOFS__TICK_EPOCH \
Decimal number that defines what epoch must produce
object notification with UTF-8 object address in a
Expand Down
4 changes: 2 additions & 2 deletions proto-docs/session.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ Session creation request body
| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| owner_id | [neo.fs.v2.refs.OwnerID](#neo.fs.v2.refs.OwnerID) | | Session initiating user's or node's key derived `OwnerID` |
| expiration | [uint64](#uint64) | | Session expiration `Epoch` |
| expiration | [uint64](#uint64) | | Session expiration epoch, the last epoch when session is valid. |


<a name="neo.fs.v2.session.CreateResponse"></a>
Expand Down Expand Up @@ -270,7 +270,7 @@ Lifetime parameters of the token. Field names taken from rfc7519.

| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| exp | [uint64](#uint64) | | Expiration Epoch |
| exp | [uint64](#uint64) | | Expiration epoch, the last epoch when token is valid. |
| nbf | [uint64](#uint64) | | Not valid before Epoch |
| iat | [uint64](#uint64) | | Issued at Epoch |

Expand Down
2 changes: 1 addition & 1 deletion session/service.proto
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ message CreateRequest {
message Body {
// Session initiating user's or node's key derived `OwnerID`
neo.fs.v2.refs.OwnerID owner_id = 1;
// Session expiration `Epoch`
// Session expiration epoch, the last epoch when session is valid.
uint64 expiration = 2;
}
// Body of a create session token request message.
Expand Down
2 changes: 1 addition & 1 deletion session/types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ message SessionToken {

// Lifetime parameters of the token. Field names taken from rfc7519.
message TokenLifetime {
// Expiration Epoch
// Expiration epoch, the last epoch when token is valid.
uint64 exp = 1 [json_name = "exp"];

// Not valid before Epoch
Expand Down

0 comments on commit 7523e27

Please sign in to comment.