Skip to content

SEC-08: the local demo of examples/local signs in with the password grant #189

Open

Description

@ephico2real2

Part of #181

What is wrong: The local run of examples/local signs its demo users in with the resource owner password grant. RFC 9700, section 2.4, says that the grant "MUST NOT be used". The run is on a throwaway Keycloak on the developer's machine with demo passwords, so no real credential is at risk. But the guide teaches the grant, and a reader can copy it.

Where: on b83391c: examples/local/keycloak_setup.py (it turns direct access grants on for cmapi-cli and cmapi-automation), examples/local/demo.py:22, examples/local/INSTALL.md:241, :467 and :509, and examples/local/transcript.txt.

How to prove it: grep -rn "grant_type.*password" examples/local prints lines today. After the fix it prints none for realm users, and examples/local/demo.py still runs its 14 scenarios.

Measured or inferred: Measured on 2026-11-13 by the grep above. Found while fixing #181, which changes the deployed realm and its proofs and leaves examples/local as it is.

Severity: Low. A local demo on a throwaway Keycloak.

What must hold after the fix: The local run signs a demo user in with deploy/oidc-login.py (the authorization code grant with PKCE), or with the device grant that docs/02 gives to cmapi-cli, and the bot with client credentials. The transcript is recorded again from a run.

Research: #181 has the choice and its sources for the deployed realm. Decide whether the demo uses the same script, and whether Keycloak's dev mode on http://localhost needs a change of the script (it sets cookies with no Secure flag there). The run needs a Keycloak container, so it waits for #157.

Solution (inline, not applied): Not written here.

Class: TDT. The demo keeps an old practice.

Activity

  1. added
    bug
    class:TDT
    status:open
    sev:low
    Backlog
    on Nov 13, 2026
  2. added a commit that references this issue on Nov 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Backlogbugclass:TDTsev:lowstatus:open

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions