summaryrefslogtreecommitdiff
path: root/certs/app/models/client_certificate.rb
diff options
context:
space:
mode:
authorelijah <elijah@riseup.net>2013-02-05 21:19:36 -0800
committerelijah <elijah@riseup.net>2013-02-05 21:19:36 -0800
commit27ef3129815acd5828064308fe1f5ea97f60bc06 (patch)
treed951ad94065770df63cbc19775a1723b19950a0d /certs/app/models/client_certificate.rb
parent7cc90df4010d83232541ab6174e38201e2fcabbb (diff)
certs -- fix bug with date calculation of 'yesterday'
Diffstat (limited to 'certs/app/models/client_certificate.rb')
-rw-r--r--certs/app/models/client_certificate.rb16
1 files changed, 8 insertions, 8 deletions
diff --git a/certs/app/models/client_certificate.rb b/certs/app/models/client_certificate.rb
index 9cde820..be0ac63 100644
--- a/certs/app/models/client_certificate.rb
+++ b/certs/app/models/client_certificate.rb
@@ -73,13 +73,13 @@ class ClientCertificate
{
"digest" => APP_CONFIG[:client_cert_hash],
"extensions" => {
- "keyUsage" => {
- "usage" => ["digitalSignature"]
- },
- "extendedKeyUsage" => {
- "usage" => ["clientAuth"]
- }
- }
+ "keyUsage" => {
+ "usage" => ["digitalSignature"]
+ },
+ "extendedKeyUsage" => {
+ "usage" => ["clientAuth"]
+ }
+ }
}
end
@@ -91,7 +91,7 @@ class ClientCertificate
##
def yesterday
- t = Time.now - 24*24*60
+ t = Time.now - 24*60*60
Time.utc t.year, t.month, t.day
end