Permalink
Browse files

update ldap search criteria to match case

  • Loading branch information...
jeffbryner committed Dec 30, 2015
1 parent af4499f commit 3519a848731b64521d78cc2796942888a02bd6ca
Showing with 3 additions and 3 deletions.
  1. +3 −3 rest/index.py
View
@@ -532,7 +532,7 @@ def esLdapResults(begindateUTC=None, enddateUTC=None):
q = pyes.FilteredQuery(q, qDate)
q = pyes.FilteredQuery(q, pyes.TermFilter('tags', 'ldap'))
q = pyes.FilteredQuery(q,
pyes.TermFilter('details.result', 'ldap_invalid_credentials'))
pyes.TermFilter('details.result', 'LDAP_INVALID_CREDENTIALS'))
q2 = q.search()
q2.facet.add_term_facet('details.result')
q2.facet.add_term_facet('details.dn', size=20)
@@ -561,9 +561,9 @@ def esLdapResults(begindateUTC=None, enddateUTC=None):
for t in results.facets['details.result'].terms:
#print(t['term'],t['count'])
if t['term'] == 'ldap_success':
if t['term'] == 'LDAP_SUCCESS':
success = t['count']
if t['term'] == 'ldap_invalid_credentials':
if t['term'] == 'LDAP_INVALID_CREDENTIALS':
failures = t['count']
resultsList.append(dict(dn=dn, failures=failures,
success=success, begin=begindateUTC.isoformat(),

0 comments on commit 3519a84

Please sign in to comment.