Răsfoiți Sursa

Deprecate Linked CA functionality in open-source step-ca

Add deprecation warnings when Linked CA features are used:
- Warning in authority.go when linkedCAToken is initialized
- Warning in app.go when --token flag is used at startup

Existing Linked CAs continue to work but now show deprecation
warnings directing users to migrate to Step CA Pro.

This is phase 1 of removing Linked CA from open-source step-ca.
A future release will remove the functionality entirely.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Carl Tashian 10 luni în urmă
părinte
comite
6ea19aa3f7
3 a modificat fișierele cu 16 adăugiri și 0 ștergeri
  1. 7 0
      CHANGELOG.md
  2. 3 0
      authority/authority.go
  3. 6 0
      commands/app.go

+ 7 - 0
CHANGELOG.md

@@ -27,6 +27,13 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
 
 ### [x.y.z] - unreleased
 
+### Deprecated
+
+- Linked CA functionality is deprecated in open-source step-ca and will be
+  removed in a future version. Existing Linked CAs will continue to work but
+  will show a deprecation warning. Users requiring Linked CA features should
+  migrate to Step CA Pro. See https://smallstep.com/product/step-ca-pro/
+
 ### Changed
 
 - Upgrade HSM-enabled Docker images from Debian Bookworm (12) to Debian Trixie

+ 3 - 0
authority/authority.go

@@ -346,6 +346,9 @@ func (a *Authority) init() error {
 
 	// Automatically enable admin for all linked cas.
 	if a.linkedCAToken != "" {
+		log.Println("DEPRECATION WARNING: Linked CA functionality in open-source step-ca " +
+			"is deprecated and will be removed in a future version. Please migrate to " +
+			"Step CA Pro. See https://smallstep.com/product/step-ca-pro/")
 		a.config.AuthorityConfig.EnableAdmin = true
 	}
 

+ 6 - 0
commands/app.go

@@ -112,6 +112,12 @@ func appAction(ctx *cli.Context) error {
 	token := ctx.String("token")
 	quiet := ctx.Bool("quiet")
 
+	if token != "" {
+		fmt.Fprintln(os.Stderr, "DEPRECATION WARNING: Linked CA (--token) in open-source "+
+			"step-ca is deprecated and will be removed in a future version. "+
+			"Please unlink your CA or migrate to Step CA Pro. https://smallstep.com/product/step-ca-pro/")
+	}
+
 	if ctx.NArg() > 1 {
 		return errs.TooManyArguments(ctx)
 	}