Validate expiry instants

Description

Throw if user specifies an Instant that would overflow the unsigned 32-bit expiry value in the wire protocol, or would be interpreted as a relative duration.

Throw if a user specifies a Duration longer than 50 years.

Environment

None

Gerrit Reviews

None

Release Notes Description

None

Activity

Show:

David Nault June 9, 2021 at 6:08 PM
Edited

Suggested release note text:

The SDK now validates document expiry arguments, and rejects extreme values that would otherwise result in the document expiring earlier or later than requested. Specifically, an InvalidArgumentException is now thrown if the expiry meets any of these criteria:

     - after 2106-02-07T06:28:15Z

     - specified as a non-zero Instant before 1970-02-01T00:00:00Z

     - specified as a non-zero Duration less than 1 second or greater than 18,250 days (~50 years)

 

Fixed
Pinned fields
Click on the next to a field label to start pinning.

Details

Assignee

Reporter

Story Points

Fix versions

Priority

Instabug

Open Instabug

PagerDuty

Sentry

Zendesk Support

Created March 10, 2021 at 5:55 PM
Updated June 22, 2021 at 5:41 PM
Resolved June 9, 2021 at 6:08 PM
Instabug