nyx/tests/fixtures/ldap_injection/ruby/baseline_constant_ldap.rb
2026-05-07 01:29:31 -04:00

9 lines
275 B
Ruby

# Baseline: filter is a literal string, no taint reaches the search call.
require "net/ldap"
class UsersController
def lookup
ldap = Net::LDAP.new(host: "ldap.example.com")
ldap.search(base: "ou=people,dc=example,dc=com", filter: "(objectClass=person)")
end
end