Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
David Goulet
Tor
Commits
c364e0e8
Commit
c364e0e8
authored
Jul 08, 2020
by
Alexander Færøy
🍍
Browse files
Merge branch 'maint-0.4.2' into maint-0.4.3
parents
a213d279
b81e24cd
Changes
2
Hide whitespace changes
Inline
Side-by-side
changes/bug40028
0 → 100644
View file @
c364e0e8
o Minor bugfixes (compiler warnings):
- Fix a compiler warning on platforms with 32-bit time_t values.
Fixes bug 40028; bugfix on 0.3.2.8-rc.
src/lib/tls/x509.c
View file @
c364e0e8
...
...
@@ -23,6 +23,7 @@ tor_tls_pick_certificate_lifetime(time_t now,
time_t
*
start_time_out
,
time_t
*
end_time_out
)
{
tor_assert
(
cert_lifetime
<
INT_MAX
);
time_t
start_time
,
end_time
;
/* Make sure we're part-way through the certificate lifetime, rather
* than having it start right now. Don't choose quite uniformly, since
...
...
@@ -36,7 +37,7 @@ tor_tls_pick_certificate_lifetime(time_t now,
const
time_t
start_granularity
=
24
*
3600
;
time_t
earliest_start_time
;
/* Don't actually start in the future! */
if
(
cert_lifetime
<=
min_real_lifetime
+
start_granularity
)
{
if
(
(
int
)
cert_lifetime
<=
min_real_lifetime
+
start_granularity
)
{
earliest_start_time
=
now
-
1
;
}
else
{
earliest_start_time
=
now
+
min_real_lifetime
+
start_granularity
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment