[jira] [Closed] (JAMES-4091) Listing connected users

"Benoit Tellier (Jira)" <[email protected]>
Newsgroups gmane.comp.jakarta.james.devel
Message-ID <[email protected]>
     [ https://issues.apache.org/jira/browse/JAMES-4091?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Benoit Tellier closed JAMES-4091.
---------------------------------
    Resolution: Fixed

> Listing connected users
> -----------------------
>
>                 Key: JAMES-4091
>                 URL: https://issues.apache.org/jira/browse/JAMES-4091
>             Project: James Server
>          Issue Type: New Feature
>          Components: IMAPServer, JMAP, SMTPServer
>            Reporter: Benoit Tellier
>            Assignee: Antoine Duprat
>            Priority: Major
>              Labels: security
>
> h3. Why?
> This could be a usefull administrative feature, for instance offered by Dovecot:
> (credits chatgpt)
> {code:java}
> Dovecot: Provides robust administrative tools, including the doveadm who command, 
> which lists all currently connected users. This functionality is exposed via the Dovecot 
> Admin socket rather than an HTTP API.
> {code}
> Given JAMES-4090 we already track opened channels, exposing the users would thus be doable easily.
> Ref https://manpages.ubuntu.com/manpages/focal/man1/doveadm-who.1.html
> This is useful for diagnostic purposes.
> h2. API proposal
> {code:java}
> curl -XGET /servers/channels/[email protected]
> {code}
> Would return all channels belonging to `[email protected]`:
> {code:java}
> [
>    {
>        "protocol": "IMAP",
>         "endpoint": "imap-ssl",
>         "encrypted": true, // SSLHandler part of the pipeline
>         "connectionDate": "2024-11-20T16:00:00Z", // Tracked via an attribute to set upon connection
>         "remoteAddress": "12.23.45.43:4378",
>         "isActive": true,
>         "username": "[email protected]",
>         "protocolSpecificInformation": {
>              "compressed": "true", // CompressHandler part of the pipeline
>              "userAgent": "outlook", // Record then read this in the IMAPSession
>              "selectedMailbox": "INBOX", // Read the IMAPSession
>              "isIdling": "true",  // Inspect behavious in protocol overrides
>              "requestCount": "1234"  // channel attribute to be incremented on channelRead
>          }   
>    },
>    {
>        "protocol": "SMTP",
>         "endpoint": "smtp-server-global",
>         "encrypted": true, // SSLHandler part of the pipeline
>         "connectionDate": "2024-11-20T16:00:00Z", // Tracked via an attribute to set upon connection
>         "remoteAddress": "12.23.45.43:4378",
>         "isActive": true,
>         "username": "[email protected]",
>         "protocolSpecificInformation": {  }   
>    },
> ...
> ]
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.