Changeset 2106ed1 for fedd/fedd_util.py


Ignore:
Timestamp:
Jun 25, 2008 2:56:12 PM (16 years ago)
Author:
Ted Faber <faber@…>
Branches:
axis_example, compt_changes, info-ops, master, version-1.30, version-2.00, version-3.01, version-3.02
Children:
8922e1b
Parents:
d26d52e
Message:

check password failures. Exception doesn_t have a message attribute under python 2.4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • fedd/fedd_util.py

    rd26d52e r2106ed1  
    163163    elif id.startswith("http:") or id.startswith("https:"): return { 'uri': id }
    164164    else: return { 'username': id}
     165
     166def unpack_id(id):
     167    """return id as a type determined by the key"""
     168    if id.has_key("fedid"): return fedid(id["fedid"])
     169    else:
     170        for k in ("username", "uri", "kerberosUsername"):
     171            if id.has_key(k): return id[k]
     172    return None
    165173
    166174def pack_soap(container, name, contents):
Note: See TracChangeset for help on using the changeset viewer.