chiark / gitweb /
Make it easier to reference another app's signature
authorCiaran Gultnieks <ciaran@ciarang.com>
Fri, 5 Apr 2013 16:02:02 +0000 (17:02 +0100)
committerCiaran Gultnieks <ciaran@ciarang.com>
Fri, 5 Apr 2013 16:02:02 +0000 (17:02 +0100)
config.sample.py
fdroidserver/publish.py

index f0e0369f1207cef0f6da76b6a8dab4175a179459..e81ab5f103caefdc5ba49d88368daf72162eca9c 100644 (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.
index c0791d27087380eaaa8b4a98de08b5844acfc889..dce4d497dce9607d5517d3d2e8ba5d5f36e581c0 100644 (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)