Readme updates + tests for cert

This commit is contained in:
Martin Lensment 2015-02-25 17:33:32 +02:00
parent 5319db16b4
commit a6baf60e59
9 changed files with 154 additions and 2 deletions

View file

@ -1,4 +1,8 @@
class Certificate < ActiveRecord::Base
include Versions
belongs_to :api_user
SIGNED = 'signed'
UNSIGNED = 'unsigned'
EXPIRED = 'expired'
@ -69,6 +73,7 @@ class Certificate < ActiveRecord::Base
if err.match(/Data Base Updated/) || err.match(/ERROR:Already revoked/)
save!
@cached_status = REVOKED
else
errors.add(:base, I18n.t('failed_to_revoke_certificate'))
logger.error('FAILED TO REVOKE CLIENT CERTIFICATE')