Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F138016029
D20151.id57019.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
574 B
Referenced Files
None
Subscribers
None
D20151.id57019.diff
View Options
Index: head/sys/kern/kern_time.c
===================================================================
--- head/sys/kern/kern_time.c
+++ head/sys/kern/kern_time.c
@@ -412,7 +412,9 @@
if (ats->tv_nsec < 0 || ats->tv_nsec >= 1000000000 ||
ats->tv_sec < 0)
return (EINVAL);
- if (!allow_insane_settime && ats->tv_sec > 8000ULL * 365 * 24 * 60 * 60)
+ if (!allow_insane_settime &&
+ (ats->tv_sec > 8000ULL * 365 * 24 * 60 * 60 ||
+ ats->tv_sec < utc_offset()))
return (EINVAL);
/* XXX Don't convert nsec->usec and back */
TIMESPEC_TO_TIMEVAL(&atv, ats);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Nov 29, 4:34 AM (17 h, 2 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
26317764
Default Alt Text
D20151.id57019.diff (574 B)
Attached To
Mode
D20151: Check for excessively small times in kern_clock_settime().
Attached
Detach File
Event Timeline
Log In to Comment