mihaifm / HIBPOfflineCheck

Keepass plugin that performs offline and online checks against HaveIBeenPwned passwords
Other
317 stars 17 forks source link

HIBP API error #31

Closed dusscloud closed 5 years ago

dusscloud commented 5 years ago

I am trying to use HIPB online. I successfully used it on a windows desktop, but on my ubuntu I get "HIBP API error" (with latest 1.4.1 version). I can access https://api.pwnedpasswords.com/range/ABCDE with my browser What could be wrong?

mihaifm commented 5 years ago

It may be due to proxy settings. On Windows it should use system proxy but I'm not sure about linux. Are you behind a proxy?

dusscloud commented 5 years ago

no proxy at all

I ran tcpdump to see what's happening. There is indeed some exchange between my laptop and pwnedpasswords.com What's weird is that after I got the "HIPB API Error" result, there is a loop of communication which stopped only after I closed keepass.

16:30:18.901211 IP6 MYIPV6ADRESS.40026 > 2606:4700::6812:ce57.443: Flags [.], ack 773, win 499, length 0 16:30:24.892109 IP6 MYIPV6ADRESS:1823.40026 > 2606:4700::6812:ce57.443: Flags [P.], seq 737:776, ack 773, win 499, length 39 16:30:24.900421 IP6 2606:4700::6812:ce57.443 > MYIPV6ADRESS.40026: Flags [P.], seq 773:812, ack 776, win 30, length 39 16:30:24.900468 IP6 MYIPV6ADRESS.40026 > 2606:4700::6812:ce57.443: Flags [.], ack 812, win 499, length 0 16:30:30.895329 IP6 MYIPV6ADRESS.40026 > 2606:4700::6812:ce57.443: Flags [P.], seq 776:815, ack 812, win 499, length 39 16:30:30.904034 IP6 2606:4700::6812:ce57.443 > MYIPV6ADRESS.40026: Flags [P.], seq 812:851, ack 815, win 30, length 39 16:30:30.904058 IP6 MYIPV6ADRESS.40026 > 2606:4700::6812:ce57.443: Flags [.], ack 851, win 499, length 0 16:30:36.898638 IP6 MYIPV6ADRESS.40026 > 2606:4700::6812:ce57.443: Flags [P.], seq 815:854, ack 851, win 499, length 39 16:30:36.911200 IP6 2606:4700::6812:ce57.443 > MYIPV6ADRESS.40026: Flags [P.], seq 851:890, ack 854, win 30, length 39 16:30:36.911260 IP6 MYIPV6ADRESS.40026 > 2606:4700::6812:ce57.443: Flags [.], ack 890, win 499, length 0

mihaifm commented 5 years ago

It could be a TLS issue if you're running an older Mono version. pwnedpasswords.com requires TLS 1.2 which was added in Mono 4.8, as far as I can see:

https://www.mono-project.com/docs/about-mono/releases/4.8.0/#tls-12-support

I'm not encountering any problems on Ubuntu so this is a bit difficult to debug.

dusscloud commented 5 years ago

$ mono --version Mono JIT compiler version 4.6.2 (Debian 4.6.2.7+dfsg-1ubuntu1) Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com TLS: __thread SIGSEGV: altstack Notifications: epoll Architecture: amd64 Disabled: none Misc: softdebug LLVM: supported, not enabled. GC: sgen

what's yours?

mihaifm commented 5 years ago
$ mono --version
Mono JIT compiler version 5.18.0.240 (tarball Wed Jan 16 09:10:16 UTC 2019)
Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com
        TLS:           __thread
        SIGSEGV:       altstack
        Notifications: epoll
        Architecture:  amd64
        Disabled:      none
        Misc:          softdebug
        Interpreter:   yes
        LLVM:          yes(600)
        Suspend:       preemptive
        GC:            sgen (concurrent by default)

I think you might need a mono update.

boldt commented 5 years ago

I had the same issue with Ubuntu 18.04 and I can confirm, that the newer mono version fixed the issue:

$ mono --version | grep version
Mono JIT compiler version 4.6.2 (Debian 4.6.2.7+dfsg-1ubuntu1)
sudo apt install gnupg ca-certificates
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
echo "deb https://download.mono-project.com/repo/ubuntu stable-bionic main" | sudo tee /etc/apt/sources.list.d/mono-official-stable.list

sudo apt update
sudo apt upgrade
mihaifm commented 5 years ago

@boldt thanks for the confirmation, I'll just add a release note mentioning the required Mono version