NetTalk Central

Author Topic: [SOLVED] Google GCM Push Notification with NetWebClient  (Read 3573 times)

walter.dasilva

  • Sr. Member
  • ****
  • Posts: 314
  • SOFTVALE
    • MSN Messenger - walter@softvale.com.br
    • View Profile
    • SOFTVALE
[SOLVED] Google GCM Push Notification with NetWebClient
« on: September 02, 2014, 07:08:25 AM »
Hi,

Ipm usign NetWebClient to access Google GCM Push Notification. So, it is working very nice. Very nice with my windows 8, windows 8.1 using IE 11.

When i move it to Windows Server 2008 or R2 that use IE 9 nothing happen.

Using Fiddler i can see the tunnel for android.googleapis.com is started, returning connected http 200, but with any information.

does anyone knows something abou it?

Thanks
Walter - SOFTVALE
« Last Edit: September 05, 2014, 04:47:58 AM by walter.dasilva »
Walter - SOFTVALE

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11171
    • View Profile
Re: Google GCM Push Notification with NetWebClient
« Reply #1 on: September 02, 2014, 07:13:11 AM »
did you unblock the program in the windows firewall?

walter.dasilva

  • Sr. Member
  • ****
  • Posts: 314
  • SOFTVALE
    • MSN Messenger - walter@softvale.com.br
    • View Profile
    • SOFTVALE
Re: Google GCM Push Notification with NetWebClient
« Reply #2 on: September 02, 2014, 11:07:16 AM »
Hi Bruce,

Firewall is off in this server, ports 5222-5223 and 5228-5230 is open on router.

Regards,
Walter - SOFTVALE
Walter - SOFTVALE

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11171
    • View Profile
Re: Google GCM Push Notification with NetWebClient
« Reply #3 on: September 02, 2014, 11:05:41 PM »
sounds like something between the server and google is blocking the traffic. What port are you using to connect to google?

>> 5222-5223 and 5228-5230

these sound like NetAuto ports, and I would not expect them to be needed when talking to google.

cheers
Bruce

walter.dasilva

  • Sr. Member
  • ****
  • Posts: 314
  • SOFTVALE
    • MSN Messenger - walter@softvale.com.br
    • View Profile
    • SOFTVALE
Re: Google GCM Push Notification with NetWebClient
« Reply #4 on: September 03, 2014, 05:11:20 AM »
Hi Bruce,

I think is something about Windows Server security, the things goes different if you run as a service.
is you run as a service i get html 302 error.

To send to server its not necessary, you is right. but it is necessary for android receiving push notification.

I´ll try more tests with IE security.

I really appreciate more tips about.

Chhers,
Walter - SOFTVALE
Walter - SOFTVALE

walter.dasilva

  • Sr. Member
  • ****
  • Posts: 314
  • SOFTVALE
    • MSN Messenger - walter@softvale.com.br
    • View Profile
    • SOFTVALE
[SOLVED] ]Re: Google GCM Push Notification with NetWebClient
« Reply #5 on: September 05, 2014, 04:47:00 AM »
Hi,

Problem "solved".

Inspecting my PHP code for test GCM I saw url.SSL = false.
I've made the same with NTWebClient, pushGCM.SSL=false and it works fine.

So, what do it does? how the things change?. i´ll have some security issue?

Thanks
Walter - SOFTVALE
Walter - SOFTVALE

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11171
    • View Profile
Re: [SOLVED] Google GCM Push Notification with NetWebClient
« Reply #6 on: September 09, 2014, 01:58:06 AM »
depends if the URL you are connecting to is SSL or not. I guess in this case not. I recommend connecting to the SSL version if it exists.

cheers
Bruce

walter.dasilva

  • Sr. Member
  • ****
  • Posts: 314
  • SOFTVALE
    • MSN Messenger - walter@softvale.com.br
    • View Profile
    • SOFTVALE
Re: [SOLVED] Google GCM Push Notification with NetWebClient
« Reply #7 on: September 09, 2014, 05:42:59 AM »
Hi Bruce,

the URL is https://android.googleapis.com/gcm/send.
Watching Fiddler, you can see tunnel negociation working.
But if i set netwebclient.ssl to true it doesn't works.

i don't understand how it works when i set netwebclient.ssl to false and still using https. Fiddler shows tunnel negociation anyway.

Could you make it clear that for me?

Thanks
Walter - SOFTVALE
Walter - SOFTVALE

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11171
    • View Profile
Re: [SOLVED] Google GCM Push Notification with NetWebClient
« Reply #8 on: September 09, 2014, 10:14:59 PM »
>> But if i set netwebclient.ssl to true it doesn't works.

can you use this web client to connect to any SSL site? perhaps it is missing the support DLL's or something. Have you got error messages on? Do you get an error message?

cheers
Bruce

walter.dasilva

  • Sr. Member
  • ****
  • Posts: 314
  • SOFTVALE
    • MSN Messenger - walter@softvale.com.br
    • View Profile
    • SOFTVALE
Re: [SOLVED] Google GCM Push Notification with NetWebClient
« Reply #9 on: September 10, 2014, 04:42:19 AM »
Hi Bruce,

If i set netwebclient.ssl to true and use https, i'm getting for the tunnel 200 connected, after that 401

If i set netwebclient.ssl to false and use https all works fine.

Cheers,
Walter - SOFTVALE
Walter - SOFTVALE