Actions
Bug #1759
closedCertifcate Signing fails in the UI with latest HEAD
Description
Steps to reproduce:
Build New VM
Git clone Foreman
bundle install --path vendor/
db:migrate (I used sqlite3 for speed)
start foreman
install foreman-proxy & sudo setup for certificate signing
Add proxy to foreman's proxy page
create new unsigned cert:
rm -rf /var/lib/puppet/
puppet master -v &
puppet agent --server `hostname -f` --certname unsigned-thing
Foreman -> Smart Proxies -> Certificates -> Click 'sign' by 'unsigned-thing'
Should fail
Updated by Ohad Levy over 12 years ago
this looks like an issue with puppet 2.7.18 where the certnames are now qouated.
if anyone could try the following patch and let me know:
diff --git a/lib/proxy/puppetca.rb b/lib/proxy/puppetca.rb
index 0f44fe7..e33adc0 100644
--- a/lib/proxy/puppetca.rb
+++ b/lib/proxy/puppetca.rb
@@ -132,10 +132,10 @@ module Proxy::PuppetCA
# parse the puppetca --list output
def certificate str
case str
- when /(\+|\-)\s+(.*)\s+\((\S+)\)/
+ when /(\+|\-)\s+["]{0,1}(.*\w)["]{0,1}\s+\((\S+)\)/
state = $1 == "-" ? "revoked" : "valid"
return { $2.strip => { :state => state, :fingerprint => $3 } }
- when /(.*)\s+\((\S+)\)/
+ when /\s*["]{0,1}(.*\w)["]{0,1}\s+\((\S+)\)/
return { $1.strip => { :state => "pending", :fingerprint => $2 } }
else
return {}
Updated by Ohad Levy over 12 years ago
- Project changed from Foreman to Smart Proxy
- Target version deleted (
1.0)
Updated by Ohad Levy over 12 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
Applied in changeset ffbd0e7d4c39e2ec40b321abf955edfae04d2dd3.
Actions