Open
Bug 87810
Opened 25 years ago
Updated 3 years ago
ssl_Time() will overflow in year 2106
Categories
(NSS :: Libraries, defect, P3)
Tracking
(Not tracked)
ASSIGNED
People
(Reporter: wtc, Unassigned)
Details
This bug report documents a limit of the ssl_Time() function.
The specification of ssl_Time() is:
/* returns an unsigned int containing the number of seconds in PR_Now() */
extern PRUint32 ssl_Time(void);
Since it uses an unsigned 32-bit integer to return the number of
seconds since 1970-01-01 00:00:00, it will overflow in year 2108
(1970 + 2 * 68). This limit is fundamental in the *specification*
of ssl_Time().
If ssl_Time() is *implemented* using the standard C library function
time(), on POSIX systems with a signed 32-bit time_t type, it will
overflow in year 2038 (= 1970 + 68).
Remarks:
1. Having gone through the pain of Y2K certification in 1998-1999,
I feel obliged to document any known limits of our time functions.
For example, the current *implementation* of PR_Now() will also
break in year 2100 (bug 350).
2. Note that I made the distinction between specifications and
implementations.
Comment 1•25 years ago
|
||
Marking future. I propose that this should be fixed in the year 2095.
Status: NEW → ASSIGNED
Priority: -- → P3
Target Milestone: --- → Future
| Reporter | ||
Comment 2•25 years ago
|
||
I just wanted to add that the current implementation
of ssl_Time() (in sslnonce.c, revision 1.7) calls time()
and hence will be accurate until the year 2038.
| Reporter | ||
Comment 3•24 years ago
|
||
Changed the QA contact to Bishakha.
QA Contact: sonja.mirtitsch → bishakhabanerjee
Updated•21 years ago
|
QA Contact: bishakhabanerjee → jason.m.reid
Updated•20 years ago
|
QA Contact: jason.m.reid → libraries
Updated•16 years ago
|
Assignee: nelson → nobody
Target Milestone: Future → ---
Updated•3 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•