mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-09-16 16:02:33 +03:00
Added the ability to override the key alias for specific applications
This commit is contained in:
parent
70ba2cb368
commit
3a01ce9146
2 changed files with 14 additions and 5 deletions
10
build.py
10
build.py
|
@ -220,9 +220,13 @@ for app in apps:
|
||||||
# If a collision does occur later, we're going to have to
|
# If a collision does occur later, we're going to have to
|
||||||
# come up with a new alogrithm, AND rename all existing keys
|
# come up with a new alogrithm, AND rename all existing keys
|
||||||
# in the keystore!
|
# in the keystore!
|
||||||
m = md5.new()
|
if keyaliases.has_key(app['id']):
|
||||||
m.update(app['id'])
|
# For this particular app, the key alias is overridden...
|
||||||
keyalias = m.hexdigest()[:8]
|
keyalias = keyaliases[app['id']]
|
||||||
|
else:
|
||||||
|
m = md5.new()
|
||||||
|
m.update(app['id'])
|
||||||
|
keyalias = m.hexdigest()[:8]
|
||||||
print "Key alias: " + keyalias
|
print "Key alias: " + keyalias
|
||||||
|
|
||||||
# See if we already have a key for this application, and
|
# See if we already have a key for this application, and
|
||||||
|
|
|
@ -22,7 +22,12 @@ keystorepass = "foo"
|
||||||
#The password for keys - the same is used for each auto-generated key.
|
#The password for keys - the same is used for each auto-generated key.
|
||||||
keypass = "foo2"
|
keypass = "foo2"
|
||||||
|
|
||||||
#THe distinguished name used for all keys.
|
#The distinguished name used for all keys.
|
||||||
keydname = "CN=Birdman, OU=Cell, O=Alcatraz, L=Alcatraz, S=California, C=US"
|
keydname = "CN=Birdman, OU=Cell, O=Alcatraz, L=Alcatraz, S=California, C=US"
|
||||||
"
|
|
||||||
|
#Use this to override the auto-generated key aliases with specific ones
|
||||||
|
#for particular applications. Normally, just leave it empty.
|
||||||
|
keyaliases = {}
|
||||||
|
keyaliases['com.example.app'] = 'example'
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue