Skip to content
cccskills
FreePublished on GitHub

configuration-credentials

Set up reusable named username and password credentials for messaging services such as email. You can keep passwords in environment variables or a secrets manager, while the configuration supplies the credential name and optional domain.

OriginalShow the original description

Configure reusable named username/password credentials for messaging consumers, including optional domains and runtime values. LDAP bind credentials belong to identity stores.

greenpau/caddy-security2,270 stars(GitHub 2,270 + cccskills 0)

Run score Not tested

See how to install

Good for

  • Configuring credentials for an email provider
  • Loading a password from an environment variable
  • Referencing a secrets-manager value in a credential

Files included (2)

  • SKILL.md4.2 KB
  • agents/openai.yaml210 B

SKILL.md (original)

Review the instructions the agent will receive before you install.

Configuration Credentials

Purpose

Use this skill to configure reusable credentials <label> blocks. These are parsed by caddyfile_credentials.go into go-authcrunch generic credentials. The Caddyfile block label becomes authcrunch's required credential name.

Credentials vs Secrets

Use credentials to create a named authcrunch credential object: a reusable name, username, password, and optional domain tuple that another configuration section can reference, such as an email messaging provider.

Use secrets to configure an external security.secrets manager and expose lookup values with the secrets:<secret_id>:<key> syntax. A secret lookup is not a credential object by itself; it is a placeholder-like value that caddy-security resolves during provisioning.

The two can be combined: put password "secrets:smtp:password" inside a credentials smtp_root block when the consumer needs a named credential, but the password should come from a secrets manager. configuration-secrets owns manager blocks and lookup rules.

Shape

{
	security {
		credentials smtp_root {
			username root
			password {env.SMTP_PASSWORD}
			domain example.com
		}
	}
}

The block accepts:

  • username <username>
  • password <password>
  • domain <name>

Only generic username/password credentials are exposed through the Caddyfile. Do not add name or kind inside the block; caddy-security injects name from <label>, and unsupported inner keys fail parsing.

username and password are required by go-authcrunch after runtime resolution. domain is optional. SMTP sending in go-authcrunch uses the resolved username and password; include domain only when a downstream consumer expects it.

All values are single tokens after Caddyfile parsing. Quote values containing spaces. Runtime environment and secret replacements also remain one argument; embedded spaces, quotes, and newlines must survive unchanged. Follow runtime resolution when changing the encoded-instruction path.

Guidance

Use environment placeholders or secret lookups for passwords:

password {env.SMTP_PASSWORD}
password "secrets:smtp:password"

Secret lookups must use the secrets:<secret_id>:<key> shape and require a matching secrets <plugin> <secret_id> block from configuration-secrets. Caddy-security resolves {env.*} and secrets:*:* values before go-authcrunch validates credentials.

Placeholders may be used in the block label and fields, but references must resolve to the same final name. For example, a messaging provider's credentials <credential_name> value must match the resolved credentials block label.

Use labels that describe the consumer, such as smtp_root, registration_smtp, or mailgun_smtp, rather than the secret value itself.

Email consumption follows configuration-messaging. Non-passwordless email providers require a credentials <credential_name> reference; passwordless email providers must not also set credentials.

LDAP bind settings are not wired through reusable credentials blocks. LDAP identity stores configure bind credentials directly with their own username and password directives.

Fixtures

Use these examples:

  • caddyfile_credentials_test.go.
  • testdata/caddyfile_adapt/testcase_authenticate_with_credentials.Caddyfile.
  • testdata/caddyfile_adapt/testcase_authenticate_with_registration.Caddyfile.

TestResolveRuntimeAppConfigEncodedInstructions and the lifecycle E2E check that an environment or secret-backed password containing spaces, quotes and a newline remains one exact credential value. They also reject a missing secret; the reload case preserves the serving deployment. These checks do not contact SMTP or establish that a server accepts the credential. Validate SMTP delivery separately when changing the consumer or its transport settings.

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

Build or troubleshoot HTTP clients for an authentication portal’s JSON login, token refresh, Documents, profile, and admin APIs. The skill explains request and response contracts, browser and native transports, and public signing-key discovery so clients can interact with the configured portal correctly.

  • Implement a JSON login client for a portal
  • Troubleshoot browser or native token refresh
  • Call profile, Documents, or admin endpoints
greenpau/caddy-security2.3KUpdated Oct 28, 2026

Investigate caddy-security deployment and runtime failures using configuration, logs, version details, and HTTP evidence. The skill helps identify a focused correction or document an unresolved issue with a useful handoff, while keeping observed facts separate from hypotheses and redacting secrets.

  • Diagnosing login, callback, or authorization failures
  • Finding a minimal correction for a Caddy configuration
  • Preparing a redacted break-fix issue report
greenpau/caddy-security2.3KUpdated Oct 28, 2026

Use these conventions to implement or review caddy-security Go code, Caddy modules, Caddyfile parsers, and HTTP integrations. Keep app boundaries and lifecycle behavior clear, delegate authentication logic to go-authcrunch, and handle errors and logs safely.

  • Reviewing a Caddyfile parser change
  • Adding a Caddy module or HTTP handler
  • Checking app lifecycle and cleanup behavior
greenpau/caddy-security2.3KUpdated Oct 28, 2026

configuration

FreeSummary

Build or review caddy-security Caddyfiles by starting with the security app and wiring authenticate or authorize routes to named portals and policies. Use its domain map to find focused guidance for the requested login, provider, storage, or integration setup.

  • Drafting a complete caddy-security Caddyfile
  • Wiring portal authentication into routes
  • Connecting authorization policies to protected paths
greenpau/caddy-security2.3KUpdated Oct 28, 2026

Configure Caddy authentication portals and connect them to protected routes. Select login backends, set trusted login and logout redirect rules, and wire portal behavior such as refresh and Documents storage while relying on focused skills for specialized settings.

  • Create a portal and connect it to protected routes
  • Choose which identity stores and providers can log in
  • Set trusted login and logout redirect destinations
greenpau/caddy-security2.3KUpdated Oct 28, 2026

Set authentication portal cookie names, prefixes, domains, paths, and browser attributes, including refresh-cookie overrides. The guidance explains naming precedence, validation, and how authorization policies must explicitly discover matching token cookies.

  • Giving portal cookies a shared prefix
  • Overriding one cookie name
  • Setting cookie paths and domains
greenpau/caddy-security2.3KUpdated Oct 28, 2026

See all skills by greenpau

Report a problem with this skill