Toon app: PostNL

Forum about forum-provided applications on Toon

Moderators: marcelr, TerrorSource, Toonz, TheHogNL

Re: Toon app: PostNL

Postby Toonz » Fri Nov 08, 2019 1:37 pm

Templar wrote:Okay, I ran update-rooted.sh -f for implementing the memory tuning options as mentioned in this post: domoticaforum.eu/viewtopic.php?f=104&am ... 540#p92392
After that the Postnl info didn't appear anymore, even after reinstalling the tsc certificates.

According to userSettings.json userid & password are stored and postnl_inbox.json has data stored.


What exactly is going on: you don't see the PostNL tile anymore or you do see the tile but no data is retrieved anymore?
if it is the latter I assume it is because of the contents of the json data (missing fields which I thought were always there for instance), can you send me a PM with the contents of the postnl_inbox.json file?
member of the Toon Software Collective
User avatar
Toonz
Forum Moderator
Forum Moderator
 
Posts: 1445
Joined: December 2016

Re: Toon app: PostNL

Postby Micha_123 » Wed Nov 13, 2019 1:01 am

PostNL dont work anymore by me.

No txt file in tmp

On tile i see only "geen packeten verwacht"

Deleted postnl app, deleted user config file,

Installed app again, set user and passwort (there wil be written in the tsc map) but app dont work.

In the tmp map there are no txt file from postnl app.


Toon1

Tsc Version 2.1.1
Micha_123
Starting Member
Starting Member
 
Posts: 17
Joined: September 2019

Re: Toon app: PostNL

Postby Toonz » Wed Nov 13, 2019 7:17 am

currently the app isn't working anymore as the postnl webserver is refusing the request to provide an access token.
I need to further dig into this, either I need to change the request headers or they have tightened their security to block apps like this permanently.
Busy period at work coming up so not sure when I can start looking into this.
member of the Toon Software Collective
User avatar
Toonz
Forum Moderator
Forum Moderator
 
Posts: 1445
Joined: December 2016

Re: Toon app: PostNL

Postby Micha_123 » Wed Nov 13, 2019 8:13 am

Thank you for the answere now i know it is not a problem by me.
Micha_123
Starting Member
Starting Member
 
Posts: 17
Joined: September 2019

Re: Toon app: PostNL

Postby Xavier » Tue Dec 17, 2019 11:01 pm

Any update about this app?
Toon2 with 5.18.8 firmware TSC 2.1.1
Apps: Sonos, Calender, garbagecalender, traffic information, webcam, doorcam, PostNL, public transport, Onkyo and weather app.
Xavier
Member
Member
 
Posts: 100
Joined: January 2019

Re: Toon app: PostNL

Postby Toonz » Tue Dec 17, 2019 11:58 pm

Xavier wrote:Any update about this app?

not yet, still on my todo list (coming holiday probably)
member of the Toon Software Collective
User avatar
Toonz
Forum Moderator
Forum Moderator
 
Posts: 1445
Joined: December 2016

Re: Toon app: PostNL

Postby Toonz » Sun Dec 22, 2019 12:20 pm

Xavier wrote:Any update about this app?

Hi, I did look into this today to see if I can get around their new security checks.
I have to say they did a proper job here.
I can't get it to work again.
The problem is that the server is not giving you an access token, the request for the token is refused whatever I do (even when copy/paste a similar request from the iOS app).
Happy for others to give it a try though.

For now I will remove the app from the ToonStore(s) completely. The source is still available at GitHub.

If you still have the app installed via ToonStore 4 you can remove it via ssh:
Code: Select all
opkg remove postnl


If you still have the app installed via ToonStore 5 you can remove it by deleting the folders postnl and postnl-1.0.5 from the folder /qmf/qml/apps

Kind regardz,

Toonz
member of the Toon Software Collective
User avatar
Toonz
Forum Moderator
Forum Moderator
 
Posts: 1445
Joined: December 2016

Re: Toon app: PostNL

Postby glsf91 » Tue Dec 24, 2019 9:14 am

Toonz wrote:Hi, I did look into this today to see if I can get around their new security checks.
I have to say they did a proper job here.
I can't get it to work again.
The problem is that the server is not giving you an access token, the request for the token is refused whatever I do (even when copy/paste a similar request from the iOS app).


I think I have a way to get this working again. I just tried in Postman with success on the desktop.
You have to do the following:

- go to (method = GET) https://jouw.postnl.nl/?pst=k-pnl_f-f_p ... v-jouwpost
This url is coming from jouw.post.nl from Inloggen/Consument. I don't know of this url in de app will be different.
In the response there is a line at the end like: <script type="text/javascript" src="/static/<long number>"></script>

- Do a POST with content-type text/plain;charset=UTF-8 to https://jouw.postnl.nl/static/<long number> with body: {"sensor_data":"111111111111" }

- go like before to: https://jouw.postnl.nl/web/token and you get the access token again.
(I used pwWebApp as client_id)
Last edited by glsf91 on Tue Dec 24, 2019 1:33 pm, edited 3 times in total.
glsf91
Member
Member
 
Posts: 142
Joined: September 2017

Re: Toon app: PostNL (Retired)

Postby TheHogNL » Tue Dec 24, 2019 9:27 am

Amazing job glsf91! Also, if that is working as you say, then the 'security' they have implemented is securtiy-by-obscurity :-)
I just did the first part in postman:
Code: Select all
<script>
      bazadebezolkohpepadr="1090884440"
</script>


Just naming the variable like that is just because they don't want you to know where it is for :)
Member of the Toon Software Collective
User avatar
TheHogNL
Forum Moderator
Forum Moderator
 
Posts: 1501
Joined: August 2017

Re: Toon app: PostNL (Retired)

Postby glsf91 » Tue Dec 24, 2019 9:50 am

TheHogNL wrote:Amazing job glsf91! Also, if that is working as you say, then the 'security' they have implemented is securtiy-by-obscurity :-)
I just did the first part in postman:
Code: Select all
<script>
      bazadebezolkohpepadr="1090884440"
</script>


Just naming the variable like that is just because they don't want you to know where it is for :)


Normally the body with sensor_data is much bigger, but this was enough.
glsf91
Member
Member
 
Posts: 142
Joined: September 2017

Re: Toon app: PostNL (Retired)

Postby Toonz » Tue Dec 24, 2019 10:13 am

Great find guys, much appreciated. Will have something to do this holiday period :-)
Expect a reborn postnl app soonish….
member of the Toon Software Collective
User avatar
Toonz
Forum Moderator
Forum Moderator
 
Posts: 1445
Joined: December 2016

Re: Toon app: PostNL

Postby Toonz » Tue Dec 24, 2019 1:01 pm

glsf91 wrote:I think I have a way to get this working again. I just tried in Postman with success on the desktop.
You have to do the following:

- go to https://jouw.postnl.nl/?pst=k-pnl_f-f_p ... v-jouwpost
This url is coming from jouw.post.nl from Inloggen/Consument. I don't know of this url in de app will be different.
In the response there is a line at the end like: <script type="text/javascript" src="/static/<long number>"></script>

- Do a POST with content-type text/plain;charset=UTF-8 to https://jouw.postnl.nl/static/<long number> with body: {"sensor_data":"111111111111" }

- go like before to: https://jouw.postnl.nl/web/token and you get the access token again.
(I used pwWebApp as client_id)


Have sent you an email.....
member of the Toon Software Collective
User avatar
Toonz
Forum Moderator
Forum Moderator
 
Posts: 1445
Joined: December 2016

Re: Toon app: PostNL

Postby glsf91 » Tue Dec 24, 2019 1:18 pm

Toonz wrote:Have sent you an email.....


Replied and edited my initial post (added GET).
glsf91
Member
Member
 
Posts: 142
Joined: September 2017

Re: Toon app: PostNL

Postby Toonz » Tue Dec 24, 2019 2:16 pm

glsf91 wrote:Replied and edited my initial post (added GET).

Thanks, all working fine now.... ( I forgot the closing '/' in the url after the static key).
The ball is back in the postnl developer court ;-)

I just noticed I get a package delivered this evening, must be Santa … ;-)

Thanks glsf91, much appreciated.

Kind regards,

Toonz
member of the Toon Software Collective
User avatar
Toonz
Forum Moderator
Forum Moderator
 
Posts: 1445
Joined: December 2016

Re: Toon app: PostNL

Postby Toonz » Tue Dec 24, 2019 2:39 pm

Hi all,

The PostNL app is back, version 1.0.6 is available in ToonStore 5.

Changelog:
- implemented workaround for the new PostNL security setup (thanks to glsf91).

Kind regardz,

Toonz
member of the Toon Software Collective
User avatar
Toonz
Forum Moderator
Forum Moderator
 
Posts: 1445
Joined: December 2016

PreviousNext

Return to Toon Apps

Who is online

Users browsing this forum: No registered users and 1 guest