Introducing The Sweep: OX’s New Live Security Research Series
Register Now
Breaking: The 2026 Vulnpocalypse Hits PHP: Four Critical RCEs, but How Dangerous Are They?
Read the Report
Are you exposed? Connect your apps in minutes.
Scan your apps free

@web-ts-toolkit/express-oidc-vault-redis-store

Latest version: v0.78.0

Overview

Last scanned
29 Nov 2026
Published
29 Nov 2026
npm package Publisher: junminahn
0 Stars
0 Forks
44 Versions
4.2K Downloads
TypeScript Repo language

Scan summary

@web-ts-toolkit/express-oidc-vault-redis-store was last scanned on 29 Nov 2026 at version 0.78.0. Risk score 0 of 100. No malicious behavior was detected.

  • Releases: 44 versions; the latest 3 were published within 3 days (27–29 Nov 2026).
  • Findings: No rules fired in version 0.78.0.
  • Downloads: 4,159 downloads.

Versions

44 versions published
Versions and the rules that fired in each
VersionPublishedStatus
0.78.0 LATEST 29 Nov 2026 No rules fired
0.77.0 28 Nov 2026 No rules fired
0.76.0 27 Nov 2026 No rules fired
0.75.0 22 Nov 2026 Not shown
0.74.0 21 Nov 2026 Not shown

No rules fired in 0.78.0

Findings

Findings for v0.78.0. The score is a capped sum of the weights of the rules that fired — not CVSS, not exploitability, and not a probability. It is not comparable across packages with different scan coverage.

The score describes 0.78.0; other versions have their own rules, not their own score.

README

The publisher’s own README, as collected from the registry.

@web-ts-toolkit/express-oidc-vault-redis-store

Redis-backed store provider for @web-ts-toolkit/express-oidc-vault.

Installation

The redis package is referenced by the quick start below, but this package treats it as a development-only dependency: the package does not import redis at runtime and accepts any client that implements the OidcVaultRedisClient contract. Install redis (or your adapter of choice) in your app.

pnpm add @web-ts-toolkit/express-oidc-vault @web-ts-toolkit/express-oidc-vault-redis-store express redis

Quick Start

import { createClient } from 'redis';
import { createRedisOidcVaultStore } from '@web-ts-toolkit/express-oidc-vault-redis-store';

const redis = createClient({ url: process.env.REDIS_URL });
redis.on('error', () => console.warn('OIDC vault Redis connection error.'));
await redis.connect();

const storeProvider = createRedisOidcVaultStore({
  client: redis,
  keyPrefix: 'oidc-vault',
});

Express Wiring Example

import express from 'express';
import { createClient } from 'redis';
import { createOidcVaultMiddleware } from '@web-ts-toolkit/express-oidc-vault';
import { createRedisOidcVaultStore } from '@web-ts-toolkit/express-oidc-vault-redis-store';

const app = express();
const redis = createClient({ url: process.env.REDIS_URL });
redis.on('error', () => console.warn('OIDC vault Redis connection error.'));

await redis.connect();

app.use(
  createOidcVaultMiddleware({
    basePath: '/auth/oidc',
    backendOrigin: 'https://api.example.com',
    config: {
      issuer: process.env.OIDC_ISSUER,
      clientId: process.env.OIDC_CLIENT_ID,
      clientSecret: process.env.OIDC_CLIENT_SECRET,
    },
    frontendRedirectUri: 'https://frontend.example.com/callback',
    postLogoutRedirectUri: 'https://frontend.example.com/logged-out',
    storeProvider: createRedisOidcVaultStore({
      client: redis,
      keyPrefix: 'oidc-vault',
    }),
  }),
);

Notes

  • use Redis in production when you need shared session state across multiple app instances
  • supported Redis topologies are standalone Redis through the official redis client, and Redis Sentinel through the underlying master client retrieved from a createSentinel(...) client (see Redis Version And Topology); Redis Cluster is not supported
  • Redis Cluster clients are rejected when the store is created because the package does not currently route multi-key vault scripts through a hash-slot adapter
  • the provider stores JSON payloads under prefixed keys for sessions, auth transactions, and one-time exchange codes
  • one-time records are consumed atomically through Redis commands instead of get plus del
  • session rotation and session indexes are updated atomically so concurrent refreshes do not fork multiple active sessions
  • rotation requires a distinct unused target session ID; missing-source, same-ID, and existing-target rotation conflicts throw OidcVaultStoreConflictError without changing source or target records
  • obsolete rotated session IDs are stored as aliases owned by the logical session; scoped/direct deletion preserves unexpired aliases while another live member survives, including another issuer/client scope. Deleting through an obsolete ID still revokes its logical lineage
  • alias cleanup runs inside the delete script alongside the primary mutation. It checks keyed primary membership with Redis TTL authority before removing terminated-lineage aliases; empty logical logout uses the same liveness rule in an atomic cleanup script. Rotation cannot interleave between that check and alias removal. The overall indexed traversal is not a global logout snapshot, so later arrivals can survive
  • Alias-cleanup compatibility: scoped/direct logout no longer discards surviving lineage handles. Successful delete scripts no longer repeat application-side alias cleanup. A fixed warmed workload of 12 rotated lineages deleted by subject used 52 client commands before and 16 after on both Redis 6.2 and 7.2 (36 fewer sequential round trips); this measures command count, not latency. Lua still materializes whole logical-member sets, probes primaries until finding a survivor, and materializes/deletes all aliases when inactive; large lineages/alias sets remain scale-dependent server work
  • creating or rotating into a previously obsolete session ID removes that stale alias ownership first, so a reused ID cannot invoke an old logical-session meaning
  • createAuthorizationTransaction and createExchangeCode are upserts; createSession is create-only and duplicate session IDs throw OidcVaultStoreConflictError without changing the existing record or indexes. Portable callers must create sessions with a fresh unused ID and handle OidcVaultStoreConflictError: reusing a live ID rejects here but replaces on memory/MongoDB, so only fresh-ID creation is portable
  • portable data consists of strings, finite numbers, booleans, null, arrays, and plain objects; exclude cycles, custom prototypes/serializers, functions, symbols, and undefined properties. This applies to nested provider/user/metadata data, not only top-level metadata
  • portable plain-object/array inputs are captured before asynchronous work, including rotation source reads and scoped deletion scans. Returned session containers are independent from caller input, including nested provider/user/metadata arrays; later caller mutation cannot change the committed portable value or eventual result
  • compatibility: session ownership snapshots do not add a JSON round-trip. The existing JSON serializer still handles native values and toJSON hooks (and still rejects unsupported values such as BigInt/cycles). Opaque non-plain objects are not recursively copied and have no portable mutation-isolation guarantee; create/rotate results retain their native values while reads reflect persisted JSON
  • backchannel logout token JTI records are consumed only when expiresAt is finite and greater than the store clock at consume time
  • the optional now hook controls store-domain timestamps and testable JTI validation only; Redis server time is the authority for Redis key expiry and revocation-index cleanup
  • the client must implement sendCommand(args); official standalone redis clients already do, and a Sentinel-wrapped master client or any adapter implementing OidcVaultRedisClient does too

Rotation Aliases And Lifetime

Rotation preserves the source logical ID when the next session omits it. Each old ID becomes a revocation alias for its immediate successor's logical ID and expiresAt. With A -> B (expiresAt=T1) -> C (expiresAt=T2), A stops working at T1 even if T2 is later or absent; B uses C's deadline. Later rotations never extend earlier aliases. getSession(A) returns null: an alias is never a readable/authentication session.

With A/L1 -> B/L1 -> C/L2, the new B alias revokes L2; earlier A keeps L1 and its original deadline, never C. Redis does not eagerly retire L1 aliases merely because rotation moves its last member elsewhere (memory does); they can remain until expiry or explicit lineage cleanup. Use distinct logical IDs for unrelated login families rather than relying on retained handles disappearing on reuse.

Without successor expiresAt, Redis and memory impose no alias time limit; MongoDB uses a finite fallback (default five minutes). Non-expiring Redis sessions and their aliases can grow without a fixed retention or size bound. Use explicit session lifetimes for portable finite windows. After an alias expires, use the live ID or the appropriate logical/subject/provider-session deletion method; core refresh preserves session expiry.

Deletion, Counts And Concurrent Arrivals

Deleting a live public ID removes that record; deleting an unexpired alias revokes its logical lineage. Logical deletion and aliases have no issuer/client filter. Subject/provider-session object inputs match each supplied issuer and clientId; string inputs omit both filters and match across providers. A retained member in another scope keeps its unexpired aliases.

Bulk deletion makes one cursor traversal, rechecks scope in each atomic delete script, and can follow a rotated-away source to matching same-lineage successors. Counts sum primary sessions actually deleted by those scripts, including such successors; expired/missing records, stale membership repair and alias cleanup do not contribute. Duplicate cursor visits or overlapping revocations do not double-count an already deleted primary. A concurrent arrival may survive, and 0 is not proof that the scope is empty. An error can follow earlier committed deletions; the complete traversal is not one transaction. MongoDB instead repeats scoped deletion until an empty query and can count expired documents awaiting TTL cleanup; memory counts live deletions during a synchronous map scan. Vault deletion does not revoke outstanding stateless access tokens or call upstream logout.

Redis Version And Topology

  • Supported minimum Redis version: 6.2. Versions 6.2 and 7.2 are exercised in integration tests. One-time consumption now uses guarded cached Lua, including legacy consumes, so old calls cannot spend guarded records.
  • Standalone Redis: supported through the official redis createClient(...) client (RedisClientType). This is the tested topological default.
  • Redis Sentinel: use an underlying master client retrieved from redis.createSentinel(...) (e.g. acquire/use patterns documented by that driver) or an adapter conforming to OidcVaultRedisClient. The bare Sentinel root has sendCommand(isReadonly, args, options?), not this store's sendCommand(args). Caller/adapter owns master acquisition, reconnect/failover and release. Automated provider tests exercise standalone 6.2/7.2, not Sentinel failover; replication/persistence guarantees are deployment-owned, and losing unexpired replay reservations during failover weakens replay protection until their window expires.
  • Redis Cluster: not supported. Cluster-shaped official clients are rejected when the store is created. The package's atomic vault scripts touch several keys without a hash-slot routing adapter, so Cluster routing could send parts of one logical operation to different nodes. Add a Cluster routing/hash-slot adapter before enabling it.

Client Lifecycle And Ownership

  • Connect the client yourself. The store never calls client.connect(), client.quit(), or client.disconnect(). Pass an already-connected client and reuse it across requests.
  • Own error listeners, reconnects, and shutdown. The store reads and writes commands but does not attach error listeners, suppress client errors, or close the client. Always register a client error listener on production connections; an unhandled client error can crash the process.
  • Graceful shutdown. Draining createSession/rotateSession/deleteSessionsBy* in-flight calls, then client.quit(), is the supported shutdown order. The store holds no background timers, so no store-side teardown is required beyond verifying in-flight operations have settled.
  • Startup and concurrency. There is no store ready() handshake: connect before accepting traffic, and provision permission to execute the documented commands and cached Lua scripts. Server-side scripts protect individual mutations from interleaving; indexed traversal and post-commit maintenance span multiple commands. They do not have a fixed total-work or completion-time bound.

Key Namespace And Migration

  • All vault keys are written as <keyPrefix>:<kind>:<id> and default to the oidc-vault prefix. Use keyPrefix when the same Redis instance stores data for multiple apps, environments, or tenants.
  • Changing the prefix is not a migration. Switching keyPrefix starts an independent empty namespace: existing sessions, indexes, aliases, exchange codes, and authorization transactions remain under the previous prefix and are neither revoked nor cleaned up by the new store. Rotate the prefix only when you are prepared to lose access to, or coordinate decommissioning of, the previous namespace.
  • New sessions created under the new prefix will not collide with the old namespace, even when ranges of session IDs overlap — keys are fully namespaced and the cleanup scan only walks the configured prefix.

Stored Data Characteristics

  • This package stores refresh tokens, ID tokens, access tokens (when present), and session metadata as plaintext JSON in Redis values. It does not encrypt the values, redact them on read, or strip token fields before returning them.
  • Audit-trail and long-term persistence safety depends entirely on your Redis deployment: AOF/RDB snapshots, replicas, backups, and slow-query logs may all retain these plaintext values. Treat the Redis instance, its backups, and any persistence or replication as trusted infrastructure with the same access control you apply to your application database.
  • ACLs, TLS, network isolation, and Redis instance boundaries are the responsibility of the operator. Run the Redis instance on a private network, enable TLS for any cross-network hop, and apply the principle of least privilege with ACL rules that limit clients to the keyspace consumed by keyPrefix.
  • The package holds no cross-version schema migration guarantee. Treat the package version as the schema owner unless a future release documents a migration path.

Expiry And Index Cleanup

OX Radar and Response Center

Find threats in your stack.

OX Radar can check high-priority threats, like critical package CVEs, against your context.

Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.

Where it’s listed

The probe returned only these fields for this server — auth requirement, protocol and tool list weren’t observed, so they’re not shown (never guessed).

  • npm @web-ts-toolkit/express-oidc-vault-redis-store

References

The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.

Powered by Read the latest findings

Scan your whole stack

Group 1261154050 1
Group 1261154050
 

From OX Research Newsroom

Copy of Template Design OX Blog (1)
Research

Thousands Of GitHub Accounts Hijacked With wfx-loot CI Secret Stealing Malware Via GitHub Actions & npm

Copy of Template Design OX Blog (2)
Research

NGINX2Root: Five Critical NGINX Flaws Expose Web Servers to Remote Code Execution

Ethersphere Hijacked With Crypto Stealing Malware (1)
npm

Ethersphere Hijacked With Crypto Stealing Malware Via Github & npm

Frame 2085668439 (1)
Group 1261154229