Fdroid server in ubuntu 19.04

I have installed fdroid server and I have problems when running the “fdroid update” command

Install everything with the command “apt install --install-recommends fdroidserver”

java --version
openjdk 11.0.3 2019-04-16
OpenJDK Runtime Environment (build 11.0.3+7-Ubuntu-1ubuntu219.04.1)
OpenJDK 64-Bit Server VM (build 11.0.3+7-Ubuntu-1ubuntu219.04.1, mixed mode, sharing)

fdroid --version
1.1.1

----ERROR--------------

root@android:/media/datos/fdroid# fdroid update
CRITICAL: Unknown exception found!
Traceback (most recent call last):
File “/usr/bin/fdroid”, line 170, in
main()
File “/usr/bin/fdroid”, line 165, in main
raise e
File “/usr/bin/fdroid”, line 146, in main
mod.main()
File “/usr/lib/python3/dist-packages/fdroidserver/update.py”, line 2000, in main
archapks, cc = process_apks(apkcache, repodirs[1], knownapks, options.use_date_from_apk)
File “/usr/lib/python3/dist-packages/fdroidserver/update.py”, line 1496, in process_apks
use_date_from_apk, ada, True)
File “/usr/lib/python3/dist-packages/fdroidserver/update.py”, line 1410, in process_apk
if not common.verify_apk_signature(apkfile):
File “/usr/lib/python3/dist-packages/fdroidserver/common.py”, line 2867, in verify_apk_signature
output = subprocess.check_output(args + [apk])
File “/usr/lib/python3.7/subprocess.py”, line 395, in check_output
**kwargs).stdout
File “/usr/lib/python3.7/subprocess.py”, line 472, in run
with Popen(*popenargs, **kwargs) as process:
File “/usr/lib/python3.7/subprocess.py”, line 775, in init
restore_signals, start_new_session)
File “/usr/lib/python3.7/subprocess.py”, line 1522, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
OSError: [Errno 8] Exec format error: ‘/usr/bin/apksigner’

-----ERROR-------------------------
root@android:/media/datos/fdroid# /usr/bin/apksigner
-bash: /usr/bin/apksigner: cannot execute binary file: Exec format error

@hans Thoughts? Is Java9/10/11 supported?

@cubanitoalex Can you get openjdk-8-jre-headless instead of 11?

1 Like

you need to apt-get install binfmt-support to fix that. I think it is
a recommends from openjdk.

1 Like

Thank you for your reply, but continue with the same error, you could send me the steps to follow to start over, what packages are necessary to avoid falling into the same error.

after installing binfmt-support, you probably need to reboot. You can
test it by running apksigner directly.

1 Like

I’m working on containers (lxc) in Proxmox that can influence my problem?

I’m still trying this time with a debian 9 i386 I appreciate the collaboration of forum friends

yeah, binfmt requires kernel support, so you might need to set it up in
your container host also. Or you could make a script that calls java to
execute the apksigner JAR, then set that in your config.py, e.g.

apksigner = '/path/to/my/apksigner'
1 Like

hello good day friend, everything is perfect and it worked for me, now I have this problem with Google Chrome

root@afrodita:/var/www/fdroid# fdroid update --create-metadata
DOES NOT VERIFY
ERROR: APK Signature Scheme v2 signer #1: Malformed additional attribute #1
ERROR:
repo/Google.Chrome_v74.0.3729.157.apk: WARNING: APK Signature Scheme v2 signer #1: Unknown signature algorithm: 0x421

WARNING: Archiving Google.Chrome_v74.0.3729.157.apk with invalid signature!
INFO: Moving Google.Chrome_v74.0.3729.157.apk from repo to archive
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
WARNING: invalid decoded string length
INFO: Generated skeleton metadata for org.mozilla.firefox
INFO: Generated skeleton metadata for com.facebook.orca
INFO: Generated skeleton metadata for org.telegram.messenger
INFO: Generated skeleton metadata for com.twitter.android
INFO: Generated skeleton metadata for org.videolan.vlc
INFO: Generated skeleton metadata for com.whatsapp
DOES NOT VERIFY
ERROR: APK Signature Scheme v2 signer #1: Malformed additional attribute #1
ERROR:
archive/Google.Chrome_v74.0.3729.157.apk: WARNING: APK Signature Scheme v2 signer #1: Unknown signature algorithm: 0x421

INFO: Creating signed index with this key (SHA256):
INFO: 2B C6 EA 64 1A A7 A1 06 12 70 C1 1D E4 5A 8B 50 1C 0E 51 B0 F7 46 33 91 3E 8E 69 42 60 70 55 4C
INFO: Creating signed index with this key (SHA256):
INFO: 2B C6 EA 64 1A A7 A1 06 12 70 C1 1D E4 5A 8B 50 1C 0E 51 B0 F7 46 33 91 3E 8E 69 42 60 70 55 4C
INFO: Ignoring package without metadata: Google.Chrome_v74.0.3729.157.apk
INFO: Finished

looks like you have an invalid APK, it says the signature doesn’t validate

1 Like

Hello everyone, I have seen that many apk do not generate the icons, it will be some bugs of the fdroid server.???

Did you slide to the right both mobile data and Wi-Fi sliders in F-Droid Settings?

/LE: they are not “generated” on your device, but downloaded

1 Like

I mean the froid server does not generate me .png of several apk

fdroid --version
1.1.1

Yeah, there is a known bug where fdroid update pulls the .xml icon when it should just skip them and find the .png files. Then there are also some APKs that have no .png icon, so in that case, there needs to be a complicated conversation based on the .xml files and some other things. There are details in the fdroidserver issue tracker. We welcome help to get those things working better.

1 Like

I think it’s great that we work as a team to make better things

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.