X-Git-Url: https://git.adam-barratt.org.uk/?p=mirror%2Fuserdir-ldap.git;a=blobdiff_plain;f=ud-ldapshow;h=2b815490d4b446ea1552e753c02b6550ed53a6f8;hp=989912948644a3a7fa38d362bce68ec7b56c4fbf;hb=2525bf73603cb6487cfcea096e2dc347ad360394;hpb=10ed90c0bd35fb4538ef4e1b28fce41052aa124f diff --git a/ud-ldapshow b/ud-ldapshow index 9899129..2b81549 100755 --- a/ud-ldapshow +++ b/ud-ldapshow @@ -83,6 +83,18 @@ if arguments[0] == "devcount": Count = Count + 1; print "There are",Count,"developers as of",time.strftime("%a, %d %b %Y %H:%M:%S +0000",time.gmtime(time.time())); +if arguments[0] == "echelon": + Attrs = l.search_s(BaseDn,ldap.SCOPE_ONELEVEL,\ + "(&(|(activity-pgp=*)(activity-from=*))(&(keyfingerprint=*)(gidnumber=800)))",\ + ["activity-pgp","activity-from"]); + Count = 0; + PGPCount = 0; + for x in Attrs: + Count = Count + 1; + if x[1].has_key("activity-pgp"): + PGPCount = PGPCount + 1; + print "Echelon has seen",Count,"developers, with",PGPCount,"PGP confirms as of",time.strftime("%a, %d %b %Y %H:%M:%S +0000",time.gmtime(time.time())); + if arguments[0] == "keystat": Attrs = l.search_s(BaseDn,ldap.SCOPE_ONELEVEL,"keyfingerprint=*",\ ["keyfingerprint"]);