Skip to content

[JENKINS-27027] Log/notify REST authentication via API token #20873

Description

@jenkins-infra-bot

Original request: SecurityListener should be notified when ApiTokenFilter approves or denies a REST authentication attempt. jglick says that the logic should be reviewed from scratch.

TL;DR:

  • Investigate how it works
  • Send events when it does not

Acceptance criteria:

  • We cover REST, CLI, Web UI...
  • Data should be forwarded to SecurityListener and logged here:
    LOGGER.log(Level.FINE, "authenticated: {0} {1}", new Object[] {details.getUsername(), groups});
     
  • Anybody should be able to attach to the Security Listener and get the information (via plugin or so)
  • Nice2have: Review Javadoc of the engine and ensure it is still correct
  • Nice2have: Document the login flow in Wiki (or Jenkins.io developer docs)
  • What should happen:

Not in scope:

  • SecurityListener Audit Trail patch is not in the scope. May be used as reference impl if we need to add new API

Originally reported by jglick, imported from: Log/notify REST authentication via API token
  • assignee: wfollonier
  • status: Resolved
  • priority: Major
  • component(s): core
  • label(s): api, logging, rest, security
  • resolution: Fixed
  • resolved: 2017-12-05T14:05:53+00:00
  • votes: 0
  • watchers: 5
  • imported: 2025-11-24
Raw content of original issue

Original request: SecurityListener should be notified when ApiTokenFilter approves or denies a REST authentication attempt. jglick says that the logic should be reviewed from scratch.

TL;DR:

  • Investigate how it works
  • Send events when it does not

Acceptance criteria:

  • We cover REST, CLI, Web UI...
  • Data should be forwarded to SecurityListener and logged here:
    LOGGER.log(Level.FINE, "authenticated: {0} {1}", new Object[] {details.getUsername(), groups});
     
  • Anybody should be able to attach to the Security Listener and get the information (via plugin or so)
  • Nice2have: Review Javadoc of the engine and ensure it is still correct
  • Nice2have: Document the login flow in Wiki (or Jenkins.io developer docs)
  • What should happen:

Not in scope:

  • SecurityListener Audit Trail patch is not in the scope. May be used as reference impl if we need to add new API

No activity

Activity on this issue will appear here.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions