PayForMe icon indicating copy to clipboard operation
PayForMe copied to clipboard

Cannot add cospend project (cannot find server)

Open Narfinger opened this issue 1 year ago • 19 comments

I tried everything to add a cospend project into this app but it always reports that it cannot find the server. The QR code gives me a giant red X and the other ones say that they cannot find the server. I am using nextcloud on a local server with a self-signed certificate but I also tried with a let's encrypt certificate. Is there a way to get better error messages?

Narfinger avatar Nov 26 '23 08:11 Narfinger

Similar issue for me. The QR code doesn't register at all though... When I try to add project manually, I can't click 'Add Project' button (it is greyed out).

CapitolRadio avatar Jan 04 '24 11:01 CapitolRadio

Same here

derTunnel avatar Jan 31 '24 09:01 derTunnel

hello, same here how to add a cospend project please?

azertylr avatar Feb 03 '24 17:02 azertylr

Do you know the app and cospend version? Did the problem start with an update of the app/cospend?

tiptoptom avatar Feb 11 '24 14:02 tiptoptom

Looks like this problem: https://github.com/julien-nc/cospend-nc/issues/258

tiptoptom avatar Feb 11 '24 15:02 tiptoptom

I managed to solve this issue this way: -use a subdomain for nextcloud (nextcloud.domain.tld) and not a subfolder -copy the link on cospend -paste it in the app -put a random value for the password

azertylr avatar Feb 11 '24 18:02 azertylr

-copy the link on cospend

Which link do you mean exactly? Does it look like this? https://nextcloud.xxx.com/apps/cospend/s/xxx

-put a random value for the password

Really a random value? Did you even set a password?

tiptoptom avatar Feb 12 '24 22:02 tiptoptom

Which link do you mean exactly? Does it look like this? https://nextcloud.xxx.com/apps/cospend/s/xxx

yes that's correct, copy this link in iOS

Really a random value? Did you even set a password?

then use the "past link" function in PayForMe: it will complete server url & username and fill the password field with a random value

it worked for me

azertylr avatar Feb 13 '24 06:02 azertylr

Well, sometimes that seems to work, sometimes it doesn't.

tiptoptom avatar Feb 16 '24 17:02 tiptoptom

The issue behind this is rate limiting in Nextcloud I believe. I also got some 429 HTTP errors when vising the shared link in my browser. (after the PayForMe was used)

maxammann avatar Mar 03 '24 18:03 maxammann

Setting:

'auth.bruteforce.protection.enabled' => false,

works around the issue.

maxammann avatar Mar 03 '24 18:03 maxammann

Hi all, thanks for providing the information! By now I work in a very different setting and it gets more and more complicated to find the time to maintain PayForMe, but all your feedback helps prioritizing it.

I will try to find the reason the Cospend communication is completely broken and fix it as soon as possible. Maybe @julien-nc can point me in the right direction?

Hustenbonbon avatar Mar 04 '24 07:03 Hustenbonbon

Question to everyone: Would you be fine with completely giving up the deprecated login method in favor for a nextcloud login?

Hustenbonbon avatar Mar 04 '24 07:03 Hustenbonbon

Question to everyone: Would you be fine with completely giving up the deprecated login method in favor for a nextcloud login?

Do you mean removing link sharing and requiring a login? That would work for me.

maxammann avatar Mar 04 '24 10:03 maxammann

Would you be fine with completely giving up the deprecated login method in favor for a nextcloud login?

For me, it's a big advantage that not all my friends who want access to the project have to create an account first. I would therefore like this option to continue to exist (if that's what you meant).

tiptoptom avatar Mar 04 '24 23:03 tiptoptom

For simplicity, cannot we use the new official sharing link? it doesn't need a password or a nextcloud account. Like: https://domain.tld/apps/cospend/s/dc19853041ebc04f444293459e2a485ce

The second option would be to work like MoneyBuster with a nextcloud account to retrieve/create new project automatically

azertylr avatar Mar 06 '24 10:03 azertylr

For simplicity, cannot we use the new official sharing link? it doesn't need a password or a nextcloud account. Like: https://domain.tld/apps/cospend/s/dc19853041ebc04f444293459e2a485ce

That is what is used right now and there seems to be an issue on how PayForMe uses that. There is also authentication involved and somehow PayForMe is triggering the bruteforce detection.

maxammann avatar Mar 06 '24 10:03 maxammann

yes it seems that it is trying to connect in loop, and not only when we validate

azertylr avatar Mar 06 '24 10:03 azertylr

I think this is the place where the error message is defined.

tiptoptom avatar Mar 06 '24 12:03 tiptoptom

@Hustenbonbon any news here? 🙈

tiptoptom avatar Dec 10 '24 17:12 tiptoptom

Yeah, any news here? The workaround 'auth.bruteforce.protection.enabled' => false like mentioned in https://github.com/julien-nc/cospend-nc/issues/258 doenst work :-) I wanna go away from splitwise

Solear avatar Dec 18 '24 07:12 Solear

I seem to hit the same issue. When I add a project I see the following log on my server:

"GET /index.php/apps/cospend/api/projects/ojef.../no-pass HTTP/1.1" 401

However, my project's share has uppercase letters in it and the authentication seems to be case-sensitive. Everything works when I manually access the link with uppercase letters:

"GET /index.php/apps/cospend/api/projects/oJEf.../no-pass HTTP/1.1" 200

I think this is the responsible line in code: https://github.com/mayflower/PayForMe/blob/49d046c70ca638d759c822653892f0881165b9b5/PayForMe/Services/NetworkService.swift#L155

saemy avatar Dec 27 '24 08:12 saemy

Hi, there is unfortunately no update nor will one come from my side. I am not working for Mayflower anymore and access for me was removed from this repository and from the apple account of Mayflower. To my knowledge, there is no one else who is picking it up. After initial positive response by Mayflower on transfering the repository and the app, my last messages were not responded to anymore.

Hustenbonbon avatar Jan 02 '25 13:01 Hustenbonbon