[WARNING] endpoint 'sign' is disabled: {"code":5200,"message":"Invalid or unknown policy"
- Dominant language
- Go
- Stars
- 9.5k
- Forks
- 1.2k
- PR merge metrics
- No merged PRs in 30d
Description
I have exactly followed following documentation to run my own CA
https://blog.cloudflare.com/how-to-build-your-own-public-key-infrastructure/
However I am not able to issue certificate because following error
`[causer@linux-05 ~]$ cfssl gencert -config config_client.json csr_client.json | cfssljson -bare db
2021/03/04 13:48:34 [INFO] generate received request
2021/03/04 13:48:34 [INFO] received CSR
2021/03/04 13:48:34 [INFO] generating key: rsa-2048
2021/03/04 13:48:35 [INFO] encoded CSR
2021/03/04 13:48:35 [ERROR] bad url: parse 192.168.56.106:8888: first path segment in URL cannot contain colon
{"code":5300,"message":"failed to connect to remote"}
Failed to parse input: unexpected end of JSON input
`
CA server is running with following logging
`[causer@linux-05 ca-data]$ cfssl serve -ca-key ca-key.pem -ca ca.pem -config config_ca.json
2021/03/04 13:43:23 [INFO] Initializing signer
2021/03/04 13:43:23 [WARNING] couldn't initialize ocsp signer: open : no such file or directory
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/authsign' is enabled
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/gencrl' is enabled
2021/03/04 13:43:23 [INFO] bundler API ready
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/bundle' is enabled
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/scaninfo' is enabled
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/info' is enabled
2021/03/04 13:43:23 [WARNING] endpoint 'ocspsign' is disabled: signer not initialized
2021/03/04 13:43:23 [WARNING] endpoint 'revoke' is disabled: cert db not configured (missing -db-config)
**2021/03/04 13:43:23 [WARNING] endpoint 'sign' is disabled: {"code":5200,"message":"Invalid or unknown policy"}**
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/newcert' is enabled
2021/03/04 13:43:23 [INFO] setting up key / CSR generator
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/newkey' is enabled
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/certinfo' is enabled
2021/03/04 13:43:23 [WARNING] endpoint 'crl' is disabled: cert db not configured (missing -db-config)
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/init_ca' is enabled
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/scan' is enabled
2021/03/04 13:43:23 [INFO] endpoint '/' is enabled
2021/03/04 13:43:23 [INFO] endpoint '/api/v1/cfssl/health' is enabled
2021/03/04 13:43:23 [INFO] Handler set up complete.
2021/03/04 13:43:23 [INFO] Now listening on 127.0.0.1:8888
`
Contributor guide
Research direction
Start by reproducing the reported `cfssl serve` and `cfssl gencert` commands with `config_ca.json`, `config_client.json`, and `csr_client.json`. Compare the configured signing policy with the server's `Invalid or unknown policy` warning and verify the endpoint behavior. Done means the documented CA setup enables signing and the client command issues a certificate without the reported errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli, security
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100