Make it easier to reference another app's signature

This commit is contained in:
Ciaran Gultnieks committed 2013-04-05 17:02:02 +01:00
1 parent fdc04fe64e
commit 0febe11eb0
2 files changed
+7

No files matched your search

+3
View File
@@ -41,6 +41,9 @@ keydname = "CN=Birdman, OU=Cell, O=Alcatraz, L=Alcatraz, S=California, C=US"
#for particular applications. Normally, just leave it empty.
keyaliases = {}
keyaliases['com.example.app'] = 'example'
#You can also force an app to use the same key alias as another one, using
#the @ prefix.
keyaliases['com.example.another.plugin'] = '@com.example.another'
#The ssh path to the server's public web root directory. This is used for
#uploading data, etc.
+4
View File
@@ -84,6 +84,10 @@ def main():
if appid in keyaliases:
# For this particular app, the key alias is overridden...
keyalias = keyaliases[appid]
if keyalias.startswith('@'):
m = md5.new()
m.update(keyalias[1:])
keyalias = m.hexdigest()[:8]
else:
m = md5.new()
m.update(appid)