{"record":{"id":"b8b878653affa714","repo":"puppetlabs/puppet","slug":"could-not-connect-to-ldap-detail","errorCode":null,"errorMessage":"Could not connect to LDAP: %{detail}","messagePattern":"Could not connect to LDAP: %(.+?)","errorType":"exception","errorClass":"Puppet::Error","httpStatus":null,"severity":"error","filePath":"lib/puppet/util/ldap/connection.rb","lineNumber":73,"sourceCode":"  def reset?\n    reset\n  end\n\n  # Start our ldap connection.\n  def start\n    case ssl\n    when :tls\n      @connection = LDAP::SSLConn.new(host, port, true)\n    when true\n      @connection = LDAP::SSLConn.new(host, port)\n    else\n      @connection = LDAP::Conn.new(host, port)\n    end\n    @connection.set_option(LDAP::LDAP_OPT_PROTOCOL_VERSION, 3)\n    @connection.set_option(LDAP::LDAP_OPT_REFERRALS, LDAP::LDAP_OPT_ON)\n    @connection.simple_bind(user, password)\n  rescue => detail\n    raise Puppet::Error, _(\"Could not connect to LDAP: %{detail}\") % { detail: detail }, detail.backtrace\n  end\nend\n","sourceCodeStart":55,"sourceCodeEnd":76,"githubUrl":"https://github.com/puppetlabs/puppet/blob/e227c27540975c25aa22d533a52424a9d2fc886a/lib/puppet/util/ldap/connection.rb#L55-L76","documentation":"Error \"Could not connect to LDAP: %{detail}\" thrown in puppetlabs/puppet.","triggerScenarios":"Thrown at lib/puppet/util/ldap/connection.rb:73 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"e227c27540975c25aa22d533a52424a9d2fc886a","analyzedAt":"2026-08-21T20:49:46.650Z","schemaVersion":2},"datasetVersion":"2026-08-21T23:17:16.201Z"}