Application Token

sfp server application-token

Manage application tokens for programmatic access to the SFP server

Commands


sfp server application-token create

Create a new application token for CI/CD and automation use.

USAGE
  $ sfp server application-token create -n <value> [--json] [-x <value>] [--sfp-server-url
    <value>] [-e <value>] [-g <value>...] [--loglevel
    trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -n, --name=<value>                (required) Name of the token
  -x, --expires-in=<value>          [default: 30] Token expiration time in days
  -e, --email=<value>               Email address for the authenticated CLI user
  --sfp-server-url=<value>          URL of the SFP server
  --json                            Format output as json
  -g, --logsgroupsymbol=<value>...  Symbol used by CICD platform to group/collapse logs
  --loglevel=<option>               [default: info] logging level for this command invocation
                                    <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>

DESCRIPTION
  Create a new application token

  Application tokens are used for:
  - CI/CD pipeline authentication
  - Automated scripts and tools
  - Service-to-service communication
  - Non-interactive authentication scenarios

EXAMPLES
  $ sfp server application-token create --name "CI Token" --expires-in 30

  $ sfp server application-token create --name "GitHub Actions" --expires-in 90 --email [email protected]

  $ sfp server application-token create --name "Jenkins Build" --expires-in 7

  $ sfp server application-token create --name "Production Deploy" --expires-in 365 --json

Token Creation Process

  1. Create the token:

  1. Save the token securely:

  1. Use in CI/CD:


sfp server application-token list

List all application tokens associated with your account.

Output example:


sfp server application-token revoke

Revoke an existing application token.

Use Cases

CI/CD Pipeline Integration

GitHub Actions:

Jenkins:

Automated Scripts

Security Best Practices

  1. Token Rotation:

    • Regularly rotate tokens (every 30-90 days)

    • Use shorter expiration for high-privilege tokens

  2. Secure Storage:

    • Store tokens in secure vaults (HashiCorp Vault, AWS Secrets Manager)

    • Never commit tokens to version control

    • Use environment variables or secret management systems

  3. Principle of Least Privilege:

    • Create separate tokens for different purposes

    • Limit token scope when possible

  4. Monitoring:

    • Regularly review token usage with list command

    • Revoke unused tokens promptly

    • Monitor for suspicious activity

Token Management Workflow

Security Warning: Application tokens have the same permissions as the user who created them. Treat them as passwords and protect accordingly.

Note: Tokens are automatically revoked upon expiration. Set appropriate expiration times based on your security requirements.

Last updated