Error getting index file, Handshake failed, certificate common name invalid errors

The F-Droid client had stopped being able to refresh any of the default repos for me, and I couldn’t install apps even from my stale repo cache.

The F-Droid repo last update date was 5 August – maybe something changed around then?

The only repo and app downloads/updates that were working for me was the NewPipe repo, which I’d manually added before.

Things I tried but that did not solve the issue:

  • Clear F-Droid app cache
  • Disable/re-enable F-Droid repo
  • Clear F-Droid app data

No matter what:

  • Repo refresh failed with “Error getting index file”
  • Could not install apps from broken repos; got error “Handshake failed[filename].apk” (in case of app on F-Droid repo).

So I started writing a post here with my issue and checked my installed F-Droid version to mention it:

  • F-Droid Version 1.0.2

Ah, that sounded old…

Everything then worked again!
It proceeded to update itself without trouble.

Then I noticed something else:

  • The F-Droid repo in the new version uses the domain, not the domain that I’m pretty sure was preconfigured in my old F-Droid installation…

So I tried going to the website at

  • Error: Certificate Common Name Invalid

That certificate was for (and only

I’ve no idea why my F-Droid hasn’t updated in so long, but I have gotten other updates.

I do know why it didn’t update for a long time in the past: my phone had “optimized battery usage” for the F-Droid client, so F-Droid stopped checking for updates for anything. For very long. Eventually I noticed and disabled battery optimization and everything seemed fine since. Definitely got updates for some apps at least thereafter.

So I see potentially two issues here:

  • A recent change to the TLS certificate served for the domain?
  • Some issue with the upgrade path from old F-Droid versions? Related: Should the repo URLs have been updated by some automated mechanism at some point?

Also, and maybe out of F-Droid control, because I know it can be a difficult issue:

  • Can F-Droid do anything to indicate it needs to be exempt from Battery Optimization and similar features of different Android flavors?

(I’m running a Samsung Galaxy Note8 here, stock Android 9–the last official firmware available.)


@uniqx @hans ?

I saw an app request this recently. Relevant:
Stack Overflow: Request Ignore Battery Optimizations How To Do It Right

I manually set this on several apps and it successfully prevents them being put to sleep by the system if I don’t open them in foreground for a long time.

fyi should redirect to (#45) · Issues · F-Droid / admin · GitLab

We migrated some of our servers. The website should be working as expected now.

(Please note that is not correct and therefore not recommended. It will always re-redirect to The F-Droid app might prevent redirects for security reasons.)

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