simonmicro/Pritunl-Fake-API

Update for Pritunl v1.30.3108.50

MANKUD opened this issue ยท 47 comments

Hello,

Could you please try to make your API work for the latest release pritunl v1.30.3108.50 as this release contains a fix for port forwarding on wireguard which is very crucial. if you are able to do it I would love to make a donation to support you.

Sure thing! Could you provide any logs what the current problem is? There is a good chance, that you have just missed to reapply the patch after updating ๐Ÿ˜

The logs when I had checked it said invalid key.

Hello,

Would you be able to help me I would really appreciate it and maybe we can have a look together if you have time.

Sure thing! Could you provide any logs what the current problem is? There is a good chance, that you have just missed to reapply the patch after updating ๐Ÿ˜

Here are a few screenshots.

image

image

image

๐Ÿคฃ - I see: pritunl/pritunl@c1772d9

Guess I have to update the script to work with that... This will take a while, as I have pretty much no time ๐Ÿ˜

Oh, I see that now he has encoded it using base64. Will it be so hard since base64 is used?

No, but I will NOT update the setup for that - at least not using bash. I guess a few lines of Python will be enough for the future.

oh ok, may I know a timeline maybe? when can we expect an update from your end?

Could you be my BETA tester? Try this: setup.py.zip

sure I would love to let me try this :)

Nvm, I had not tested the script - it is broken... Working on that...

yes, I tried and it seems like its broken as you mentioned.

BTW I downgraded to pritunl v1.30.3102.46 (last version supported by your current fake API)and then ran your script which worked fine after that I manually replaced the wg port forwarding fix files i.e clients.py and instance.py and now the wg fix is working on an older version where your old fake api works.

2nd try setup.py.zip

let me give it a try

2nd try setup.py.zip

does not seem to be working I have to run this instead of your old script right?

Yes, this is strange... I'm investigating...

oh ok no problem take your time :)

Hi, the script ran successfully but the fake API emulation is not working.

image

no pop up here

image

image

Here we go again: setup.py.zip

oh ok great that was quick let me try.

looks like added 3 more things.

image

image

looks like it did not work I cannot see advanced options for users :(

image

Yes, I've just seen that error. Looks like they changed how the CSS file is passed on...

so it means more digging into it and adding more lines of code into the script?

Theoretically I just have to mitigate pritunl/pritunl@70b354a on my side...

...on it...

Done. I'll push everything soon โ„ข๏ธ

Can you confirm?

confirm? I did not understand tell me what I need to do?

Just restart your server after applying the script. I've just updated the api endpoint to be compatible with the newest version!

ok I am on it.

OMG perfect you are awesome looks like it is finally fixed.

image

image

check your sponsor's page :)

Thank you very much ๐Ÿ˜Š ๐Ÿคฏ

Hello,

The script seems to be broken again on the latest release. Maybe the developer has again changed something.

image

image

image

Just making sure: You rerun the setup.py after updating? Because I do not see any relevant code changes...

Yes, I already tried that it does not fix it. I think the changes are hidden this time may be as I too did not find any significant changes in the code related to this.

Sadly both the Docker image (goofball222/pritunl) and the Debian packages (https://repo.pritunl.com/stable/apt/pool/) do not contain this version yet. Therefore I'm unable to investigate this (yet). Feel free to open up a new issue if the problem persist (even after a cold-boot of the server - maybe some caching is going on here?). Overall this seems very strange...

What I noticed is that the latest release is usually not available as a package update via the repository and we have to manually download it using wget package name and then run dpkg -i package name to manually update to the latest release.

Argh sh*t. here we go again: pritunl/pritunl@97f08a9

Please open a new issue for this - that will take a while... I guess this only affects the subscription UI...

Yes, right I was about to share the same. Looks like the developer is following Pritunl-Fake-AP very closely ๐Ÿคฃ

Alright, I will open a new issue and you can take your time for this one no problem ๐Ÿ˜„

I see this now will it be even possible anymore?

cipher = Cipher(
algorithms.AES(key),

Yes, it is - he uses symmetric encryption with not-so-secret secrets... BUT the faked API is written in PHP, so getting the proper "encryption" (more an obfuscation) running on the api side will be very challenging. Maybe I'll just ship a patch with the setup.py which reverts that "feature", but this is a little more intrusive than just changing the hard-coded endpoint URL. I'll have to think about this and won't fix this just as fast as his previous breaking change.

I totally understand and I would love to test it whenever you are able to make a patch for pritunl v1.30.3112.0 ๐Ÿ˜„