Skip to content

Commit 051e7f7

Browse files
authored
Merge pull request #75 from keyfactor-pub/release-1.1
feat(oauth): Implement OAuth as available auth mechanism (60105)
2 parents 8dd6d64 + b097480 commit 051e7f7

39 files changed

Lines changed: 2648 additions & 990 deletions

.github/workflows/test.yml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
go-version-file: 'go.mod'
2626
cache: true
2727
- run: go mod download
28-
- run: go build -v .
28+
- run: make build
2929
- name: Run linters
3030
uses: golangci/golangci-lint-action@08e2f20817b15149a52b5b3ebe7de50aff2ba8c5 # v3.4.0
3131
with:
@@ -62,25 +62,24 @@ jobs:
6262
- '1.4.*'
6363
- '1.5.*'
6464
steps:
65-
# Deploy an ephemeral EJBCA and SignServer for CI testing
66-
- uses: m8rmclaren/ejbca-signserver-k8s@main
67-
with:
68-
deploy-k8s: 'true'
69-
deploy-nginx-ingress: 'true'
7065
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0
7166
- uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0
7267
with:
7368
go-version-file: 'go.mod'
7469
cache: true
75-
# Place the contents of ${{ secrets.EJBCA_CLIENT_CERT_PATH }} into a file at /tmp/certs/ejbca.pem
76-
- run: mkdir -p /tmp/certs && echo "${{ secrets.EJBCA_CLIENT_CERT }}" > /tmp/certs/ejbca.pem
7770
- uses: hashicorp/setup-terraform@a1502cd9e758c50496cc9ac5308c4843bcd56d36 # v3.0.0
7871
with:
7972
terraform_version: ${{ matrix.terraform }}
8073
terraform_wrapper: false
8174
- run: go mod download
75+
# Deploy an ephemeral EJBCA and SignServer for CI testing
76+
- uses: m8rmclaren/ejbca-signserver-k8s@main
77+
with:
78+
deploy-k8s: 'true'
79+
deploy-nginx-ingress: 'true'
80+
deploy-signserver: 'false'
81+
8282
- env:
83-
EJBCA_CERTIFICATE_SUBJECT: "CN=example.com"
8483
TF_ACC: "1"
8584
run: go test -v -cover ./internal/ejbca/
8685
timeout-minutes: 10

.gitignore

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ website/vendor
3434
!command/test-fixtures/**/*.tfstate
3535
!command/test-fixtures/**/.terraform/
3636

37-
# Keep windows files with windows line endings
3837
*.winfile eol=crlf
3938
*.pem
40-
terraform-provider-ejbca
39+
bin
40+
.build

.go-version

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
1.22.3

.golangci.yml

Lines changed: 24 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,31 @@
1-
# Visit https://golangci-lint.run/ for usage documentation
2-
# and information on other useful linters
3-
issues:
4-
max-per-linter: 0
5-
max-same-issues: 0
1+
run:
2+
# timeout for analysis, e.g. 30s, 5m, default is 1m
3+
timeout: 12m
4+
5+
skip-dirs:
6+
- testdata$
7+
- test/mock
8+
9+
skip-files:
10+
- ".*\\.pb\\.go"
611

712
linters:
8-
disable-all: true
913
enable:
14+
- bodyclose
1015
- durationcheck
11-
- errcheck
12-
- exportloopref
13-
- forcetypeassert
14-
- godot
15-
- gofmt
16-
- gosimple
17-
- ineffassign
18-
- makezero
16+
- errorlint
17+
- goimports
18+
- revive
19+
- gosec
1920
- misspell
20-
- nilerr
21-
- predeclared
22-
- staticcheck
23-
- tenv
21+
- nakedret
2422
- unconvert
2523
- unparam
26-
- unused
27-
- vet
24+
- whitespace
25+
- gocritic
26+
- nolintlint
27+
28+
linters-settings:
29+
revive:
30+
# minimal confidence for issues, default is 0.8
31+
confidence: 0.0

.markdownlint.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
MD013: false
2+
# We are not interested on requesting output when using "$" on shell documentation
3+
MD014: false
4+
MD024:
5+
siblings_only: true
6+
# we use emphasis on all node attestors
7+
MD036: false

.tool-versions

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
golangci_lint v1.55.0
2+
markdown_lint v0.37.0

CHANGELOG.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1-
## 0.1.0 (Unreleased)
1+
# v1.0.0
2+
## Features
3+
* First public release of EJBCA Terraform Provider
4+
* Create and manage state of certificates requested from EJBCA. The ejbca_certificate resource requires a PEM-encoded PKCS#10 certificate, and uses the EJBCA PKCS#10 Enrollment endpoint. The end-entity, specified by end_entity_name, is either created in EJBCA or used for enrollment if it already exists.
5+
* EJBCA Community & EJBCA Enterprise are both supported.
26

3-
FEATURES:
7+
# v1.1.0
8+
## Features
9+
* mTLS and OAuth now supported authentication mechanisms.
10+
* Support automatic renewal of certificates expiring within `early_renewal_hours`.
11+
* Resource now flags for recreation in plan modifier step if certificate has been revoked in EJBCA.
12+

0 commit comments

Comments
 (0)