Skip to content

Conversation

@rudraditya21
Copy link
Contributor

@rudraditya21 rudraditya21 commented Jan 25, 2026

Fixes Issue: #20889

This change adds negative caching to the LDAP entry cache so missing objects are recorded and subsequent lookups by DN, sAMAccountName, or SID return nil without re-querying the directory. It introduces a missing-entry sentinel, tracks misses per identifier type, and updates AD lookup helpers to short‑circuit on cached misses and record misses when a lookup returns no entry.

@rudraditya21 rudraditya21 changed the title added: negative caching for LDAP lookup misses (Fixes Issue: 20889) added: negative caching for LDAP lookup misses Jan 25, 2026
@smcintyre-r7 smcintyre-r7 linked an issue Jan 26, 2026 that may be closed by this pull request
@smcintyre-r7 smcintyre-r7 moved this from Todo to Ready in Metasploit Kanban Jan 28, 2026

def initialize(*args)
super
max_size = args.first || 1000
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we pass in the key word argument max_size and reference it here instead of .first?

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

Labels

Projects

Status: Ready

Development

Successfully merging this pull request may close these issues.

LDAP Cache Doesn't Store Misses

4 participants