summaryrefslogtreecommitdiffstats
path: root/lib/puppet
diff options
context:
space:
mode:
Diffstat (limited to 'lib/puppet')
-rw-r--r--lib/puppet/ssl/certificate.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/puppet/ssl/certificate.rb b/lib/puppet/ssl/certificate.rb
index 4887708f8..16af85d06 100644
--- a/lib/puppet/ssl/certificate.rb
+++ b/lib/puppet/ssl/certificate.rb
@@ -11,4 +11,9 @@ class Puppet::SSL::Certificate < Puppet::SSL::Base
extend Puppet::Indirector
indirects :certificate, :terminus_class => :file
+
+ def expiration
+ return nil unless content
+ return content.not_after
+ end
end