| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
| |
| |
| | |
defaults section, rather than the puppetd section.
|
| |
| |
| |
| |
| | |
It uses an instance of SSL::Host for getting its certificate
and ssl store.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
responsibilities to the SSL::Host class.
I was previously saving invalid CRLs unless they'd had a revocation
done in them; this commit fixes them so that they're always valid.
Also, I've added to SSL::Host the ability to generate a valid
SSL Store, suitable for validation. This is now used by
Webrick and can be used by the http clients, too.
This should have been two commits, but I'm kind of down the
rabbit hole ATM.
|
| |
| |
| |
| |
| |
| |
| |
| | |
appropriate.
It uses the CA singleton method to determine
whether it's on valid CA host, and if so, uses
the CA instance to sign its generated CSR.
|
| |
| |
| |
| |
| |
| |
| | |
I realized that it never made sense to have a CA
that didn't know how to initialize itself, so we
now have a singleton method for the CA, and it also
automatically initializes itself.
|
| |
| |
| |
| |
| |
| |
| |
| | |
The code is much cleaner, and it seems to be mostly
functional, but we have to pick a strategy for signing
the host's certificate on first startup. Also, I haven't
actually done end-to-end testing yet, which needs the certs
working first.
|
| | |
|
| |
| |
| |
| |
| | |
This provides the backward compatibility for webrick,
and only Mongrel is left.
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This provides the interface for configuring backward compatibility
in the new-style server code. It requires a completely different
configuration step, in that REST and xmlrpc handlers are configured
separately, rather than using the same handler names, but this was
considered less evil than having a large abstraction layer for specifying
how the handlers are related.
|
| |
| |
| |
| |
| | |
Now I just need to get xmlrpc working alongside REST in
both mongrel and webrick.
|
| | |
|
|\|
| |
| |
| |
| |
| | |
Conflicts:
bin/puppetca
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
saves to the :localcacert instead of :cacert.
This way the :ca terminus saves to :cacert and the :file
terminus saves to :localcacert.
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| | |
The CRL was not correctly being added to the Store used
for verification.
It does not appear to be working, though, since revoked
certificates still pass verification.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This class provides all of the semantics from puppetca,
and appears to entirely duplicate the behaviour of the existing
executable, with basically all of the code in a library
file, instead of the executable.
As such, I've deleted the test for the executable. We should have
one, but it's not nearly as important.
|
| |
| |
| |
| | |
rather than an instance method.
|
| |
| |
| |
| |
| |
| |
| | |
This commit adds 'list' and 'print' support to the CA.
They're mostly delegator methods, but now the CA should be
the sole interface for puppetca.
|
| |
| |
| |
| |
| |
| | |
Certificate revocation now works, the CA knows how
to generate the CRL, and the SSL::Host class knows
how to configure the CRL class for indirection.
|
| |
| |
| |
| |
| | |
The new-style CA now keeps track of all of its signed
certificates in its inventory file.
|
| | |
|
| |
| |
| |
| | |
first cert is added, so it's easier to test.
|
| | |
|
| |
| |
| |
| |
| | |
This models the existing Inventory module in the sslcertificates/
directory, but does so as an instance, rather than a module.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Without this, then you could end up duplicating your CA
key into the normal directory depending on how caching
was set up.
Again, this design aspect isn't the most straightforward,
but at least it's functional now.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previously, the class was returning OpenSSL instances
(e.g, OpenSSL::X509::Certificate) instead of Puppet instances
(e.g., Puppet::SSL::Certificate). This made some things
easier, but it made them asymmetric (e.g., you assigned the
key as a Puppet instance but got back an OpenSSL instance), and
it also reduced your flexibility and introspectiveness.
|
| |
| |
| |
| | |
cert.
|
| |
| |
| |
| |
| | |
This flushed out some problems, and things mostly look good
now, but I don't think we're quite there yet.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This was necessary because when the Indirector is used, there
isn't necessarily enough context available to know when a
password file should be used (e.g., when reading a Key from disk,
you don't know if that key was encrypted).
Now, the Key class automatically uses the right password file, and
only tries to use those files that actually exist.
This isn't very flexible, in that it only allows one CA file and
one non-CA file, but no one really uses anything but
the CA file anyway.
|
| |
| |
| |
| |
| |
| |
| |
| | |
terminus classes, rather than the normal :file classes.
This is unfortunately complicated, and it means that the Key
:ca_file is only ever actually used for retrieving the CA key
itself.
|
| |
| |
| |
| |
| | |
cache classes. Also, defaulting to the :file terminus
for all of the SSL classes.
|
| | |
|
| |
| |
| |
| |
| |
| | |
It previously was a subclass of Host, but this should make it
easier to separate between the thing doing the signing and the
thing managing the necessary files.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This is a kind of weird design situation. For instance, we've got a
collection of certificates in the :certdir, but then there's a special
CA certificate off by itself. Rather than build a whole separate
infrastructure for managing those separate files (cert and key, at least),
I decided to add special support for specifying where to find the CA-specific
bits, and then code for handling them when necessary.
This requires that we have a standard way of knowing whether we should be
managing the CA bits or normal host files. The Puppet::SSL::Host class now has
a 'ca_name' method that returns the string we're using for the CA name; this
name is currently 'ca'. We have to use a name, because the name is the only
thing that all methods have access to (e.g., when trying to 'find' the right
cert, we only have the name available).
What this means is that if you want access to the CA key or cert, then create
a Puppet::SSL::Host instance with the name 'ca'.
You'll still get the CA cert created with the host's :certname; it will just
be stored in a different location.
|
| |
| |
| |
| | |
now returns false on missing files, rather than failing.
|
| |
| |
| |
| |
| | |
a terminus. Also, getting rid of some metaprogramming
that wasn't really helping.
|
| |
| |
| |
| |
| | |
specifying the terminus class. The individual ssl
classes now work, but the ssl host class doesn't yet.
|
| |
| |
| |
| | |
thing to readable human text.
|
| | |
|
| |
| |
| |
| | |
revocation list.
|
| |
| |
| |
| | |
and the SSL::Host class.
|
| |
| |
| |
| |
| |
| | |
requests and return certificates. There's still plenty
more work to do, but I'm probably not much more than a
day away from redoing puppetca to use this code.
|
| |
| |
| |
| |
| |
| | |
I probably am going to skip the tests for the rest, since
the code is unlikely to ever change, and it's going to be
a royal pain to test.
|
| | |
|
| | |
|