Commit Graph
37 Commits
Author SHA1 Message Date
jetstack-botandGitHub 6348c6ffca Merge pull request #722 from autonomic-ai/support-ec-keys
Add keyAlgorithm and keySize fields to Certificates, and support ECDSA keys
2018-07-18 10:00:36 +01:00
Afolabi Badmos 445e522432 Add support for EC keys
- This PR adds two fields to CertificateSpec:
  - `keyAlgorithm`, denotes which algorithm to use when generating
    a private key. Can be either `rsa` or `ecdsa`. When not set, the
    default algorithm used `rsa`.
  - `keySize`, denotes the key size of the private key being generated.
    For `rsa`, minimum key size is 2048 and maximum is 8192.
    For `ecdsa`, sizes 224, 256, 384 & 521 are supported.
    See https://golang.org/pkg/crypto/elliptic

- `keySize` can be set without being explicit about `keyAlgorithm`.
  - If `keySize` is specified and `keyAlgorithm` is not provided, `rsa` will
    be used as the key algorithm.

- `keyAlgorithm` can be set without being explicit about `keySize`.
  - If `keyAlgorithm` is specified and `keySize` is not provided, key size
    key size of `256` will be used for `ecdsa` key algorithm and
    key size of `2048` will be used for `rsa` key algorithm.

- helper functions in `pki` package now return crypto.PrivateKey
2018-07-17 12:42:07 -04:00
Louis Taylor 969c4530a0 Add Contains util function 2018-07-12 10:27:05 +01:00
James Munnelly 1fd8cdf13e Create common GenerateCSR and GenerateTemplate methods for creating Certificate/CertificateRequest 2018-06-08 15:15:27 +01:00
James Munnelly b934852775 Merge branch 'master' into acmev2 2018-04-09 16:52:34 +01:00
Euan Kemp 6b4e33a483 util/useragent: use more verbose version 2018-04-06 18:09:52 -07:00
Euan Kemp 9c3b4e83b4 pkg/util/kube: set user-agent
This should make it slightly easier to filter api-server logs for
cert-manager activity
2018-04-06 18:09:17 -07:00
Euan Kemp 7f12fb346c issuer/acme: move 'user-agent' logic to util
This logic should be shared by things like the aws client as well.
2018-04-06 18:09:11 -07:00
James Munnelly b866b8cdf4 Fix bug in EqualUnsorted when comparing lists of the same length 2018-04-04 23:40:08 +01:00
James Munnelly f2ddd1d111 Change DNSNames/CommonNameForCertificate function to not return an error 2018-04-04 23:37:37 +01:00
James Munnelly c3be0f204e Add ingress-shim controller to create Certificates based on annotations on ingress resources 2017-11-30 22:53:54 +00:00
jetstack-botandGitHub e32147b695 Merge pull request #183 from munnerz/fix-issue-loop
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Improve validation of certificates. Fix bug in checking certificate validity

**What this PR does / why we need it**:

Improves the validation of dnsNames and commonNames on certificate resources.
Fixes a bug in checking certificate validity.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

Fixes #176, fixes #175

**Release note**:
```release-note
Fix a bug in checking certificate validity and improve validation of dnsNames and commonName
```
2017-11-04 01:00:30 +00:00
James Munnelly ffbfe2da3d Use ordered RemoveDuplicates. Add additional test cases. 2017-11-04 00:44:08 +00:00
James Munnelly 74d711ceef Add unit tests for cert->dnsName and cert->CN functions 2017-11-04 00:10:42 +00:00
James Munnelly f3db0df7b6 Add RemoveDuplicates unit test 2017-11-03 23:58:25 +00:00
James Munnelly 6ac437699d Improve validation of certificates. Fix bug in checking certificate validity 2017-11-03 23:48:18 +00:00
James Munnelly 422f8fc4be Add basic validation to ACME issuer 2017-11-03 23:35:58 +00:00
James Munnelly fa7e052ac1 Move to github.com/jetstack/cert-manager repo 2017-11-03 16:41:39 +00:00
James Munnelly eb4be6859e Update controllers and issuers for new SharedInformerFactory 2017-11-03 15:26:19 +00:00
James Munnelly 9d933d9e11 Only update certificate status in the controller package to stop conflicts 2017-10-13 20:15:29 +01:00
James Munnelly 01e5833825 Make acmesolver image configurable through CLI. Use tagged version as default. 2017-10-13 16:39:06 +01:00
James Munnelly 187e91f9ae Default commonName to first altName if not specified 2017-10-13 12:50:07 +01:00
James Munnelly f8107e6fcc Use CommonName and AltNames fields on Certificate resource 2017-10-13 12:50:07 +01:00
James Munnelly a2d9733f21 Update implementation for new field names/types 2017-10-13 11:43:52 +01:00
James Munnelly 852e250a69 Add clusterissuer controller 2017-09-22 00:10:42 +01:00
James Munnelly 940b26127b Create context for each resource to be processed 2017-09-21 20:26:27 +01:00
James Munnelly 89588bb281 Split GetKeyPair method into two methods 2017-09-10 22:54:55 +01:00
James Munnelly 2e551f58b5 Update ACME implementation for new structure. Add util/pki. 2017-09-10 21:13:37 +01:00
James Munnelly dc4335754f Move kube related utilities out of cmd 2017-09-10 21:11:34 +01:00
James Munnelly f66855bd03 Add event recording. Split out cmd entrypoint. 2017-09-09 18:27:35 +01:00
James MunnellyandGitHub 03fbe101b6 Delete unused QueueingEventHandler definition 2017-08-07 17:04:32 +01:00
James Munnelly 1d34e6a0b3 Add imports in util package 2017-08-06 23:58:20 +01:00
James Munnelly 7d8683bd16 Move solver into standalone binary. Launch Jobs to solve HTTP01 challenges. 2017-08-06 23:51:10 +01:00
James Munnelly 3fb49ad049 Refactor control loops to be more akin to kube-controller-manager 2017-08-05 00:35:54 +01:00
James Munnelly 268ae4ee89 Refactor common functions into util. Add renewals. 2017-07-22 11:45:30 +01:00
James Munnelly afbe0ba9c5 add start of authorization 2017-07-22 01:23:25 +01:00
James Munnelly 95cba8ab5f Add acme issuer. Implement 'Setup' method. Now manages ACME accounts. 2017-07-21 15:18:39 +01:00