From: Peter Palfrader Date: Tue, 8 Jul 2008 07:44:46 +0000 (+0200) Subject: ud-info: fix changing of DD status/DD status comment - we were missing prompt informa... X-Git-Tag: userdir-ldap-0.3.34~4 X-Git-Url: https://git.adam-barratt.org.uk/?a=commitdiff_plain;h=86a2cb531c55baec854944024f243e4d9def08e9;hp=c0d17c415af9716cca033e6dab59aaa4d713c06e;p=mirror%2Fuserdir-ldap.git ud-info: fix changing of DD status/DD status comment - we were missing prompt information so we got a backtrace. ud-info: Warn when we don't have a prompt string for attributes on startup. --- diff --git a/debian/changelog b/debian/changelog index 46c05b4..b825cec 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,12 @@ +userdir-ldap (0.3.XX) unstable; urgency=low + + * ud-info: fix changing of DD status/DD status comment - + we were missing prompt information so we got a backtrace. + * ud-info: Warn when we don't have a prompt string for + attributes on startup. + + -- Peter Palfrader Tue, 08 Jul 2008 09:44:39 +0200 + userdir-ldap (0.3.33) unstable; urgency=low * add "security simple_bind=128" to sample slapd.conf. diff --git a/ud-info b/ud-info index 795584b..a94ff91 100755 --- a/ud-info +++ b/ud-info @@ -116,7 +116,10 @@ AttrPrompt = {"cn": ["Common name or first name"], "labeledURI": ["Web home page"], "jabberJID": ["Jabber ID"], "icqUin": ["ICQ UIN Number"], - "VoIP": ["VoIP Address"]}; + "VoIP": ["VoIP Address"], + "accountStatus": ["DD status"], + "accountComment": ["DD status comment"], + }; # Create a map of IDs to desc,value,attr OrderedIndex = {}; @@ -125,6 +128,10 @@ for at in AttrInfo.keys(): OrderedIndex[AttrInfo[at][1]] = [AttrInfo[at][0], "", at]; OrigOrderedIndex = copy.deepcopy(OrderedIndex); +for id in OrderedIndex: + if not AttrPrompt.has_key( OrderedIndex[id][2] ): + print "Warning: no AttrPrompt for %s"%(id) + # Show shadow information def PrintShadow(Attrs): Changed = int(GetAttr(Attrs,"shadowLastChange","0")); diff --git a/userdir_gpg.py b/userdir_gpg.py index 9b497b2..273ac47 100644 --- a/userdir_gpg.py +++ b/userdir_gpg.py @@ -368,10 +368,15 @@ def GPGCheckSig(Message): Why = "Unable to verify signature, signing key missing."; # Expired signature - if Split[1] == "SIGEXPIRED" or Split[1] == "EXPSIG": + if Split[1] == "EXPSIG": GoodSig = 0; Why = "Signature has expired"; - + + # Expired signature + if Split[1] == "EXPKEYSIG": + GoodSig = 0; + Why = "Signing key (%s, %s) has expired"%(Split[2], Split[3]); + # Revoked key if Split[1] == "KEYREVOKED" or Split[1] == "REVKEYSIG": GoodSig = 0;