|
a/Allura/allura/model/auth.py |
|
b/Allura/allura/model/auth.py |
|
... |
|
... |
74 |
_id = FieldProperty(S.ObjectId)
|
74 |
_id = FieldProperty(S.ObjectId)
|
75 |
user_id = ForeignIdProperty('User')
|
75 |
user_id = ForeignIdProperty('User')
|
76 |
api_key = FieldProperty(str, if_missing=lambda:h.nonce(20))
|
76 |
api_key = FieldProperty(str, if_missing=lambda:h.nonce(20))
|
77 |
secret_key = FieldProperty(str, if_missing=h.cryptographic_nonce)
|
77 |
secret_key = FieldProperty(str, if_missing=h.cryptographic_nonce)
|
78 |
expires = FieldProperty(datetime, if_missing=None)
|
78 |
expires = FieldProperty(datetime, if_missing=None)
|
79 |
capabilities = FieldProperty({str:str}, if_missing={})
|
79 |
capabilities = FieldProperty({str:str})
|
80 |
|
80 |
|
81 |
user = RelationProperty('User')
|
81 |
user = RelationProperty('User')
|
82 |
|
82 |
|
83 |
def authenticate_request(self, path, params):
|
83 |
def authenticate_request(self, path, params):
|
84 |
try:
|
84 |
try:
|