Upload to GCMMap only in https now #2

Open
opened 2019-04-21 09:40:03 +02:00 by steffen · 5 comments
Owner

Author: @snarkbe

The upload to gmcmap.com does not work anymore.
journalctl shows

Apr 21 09:34:35 pihole gclog[30652]: CPM: 28 (= 1662/60), Timestamp: Sun Apr 21 07:33:35 2019
Apr 21 09:34:36 pihole gclog[30652]: [WARNING] Upload to gmcmap.com failed.

When I try to simulate an upload from command-line, I get:

$ curl -v "www.gmcmap.com/log2.asp?AID=01234&GID=1234567890&CPM=33"
*   Trying 184.168.224.226...
* TCP_NODELAY set
* Connected to www.gmcmap.com (184.168.224.226) port 80 (#0)
> GET /log2.asp?AID=01234&GID=1234567890&CPM=33 HTTP/1.1
> Host: www.gmcmap.com
> User-Agent: curl/7.52.1
> Accept: */*
>
< HTTP/1.1 301 Moved Permanently
< Content-Type: text/html; charset=UTF-8
< Location: https://www.gmcmap.com/log2.asp?AID=01234&GID=1234567890&CPM=33
< Server: Microsoft-IIS/8.0
< X-Powered-By: ASP.NET
< X-Powered-By-Plesk: PleskWin
< Date: Sun, 21 Apr 2019 07:36:56 GMT
< Content-Length: 194
<                                                                                                                                                              <head><title>Document Moved</title></head>
* Curl_http_done: called premature == 0
* Connection #0 to host www.gmcmap.com left intact
<body><h1>Object Moved</h1>This document may be found <a HREF="https://www.gmcmap.com/log2.asp?AID=01234&amp;GID=1234567890&amp;CPM=33">here</a></body>

So it looks like they're now redirecting all requests to https, which is not supported by the code in gclog.c .

Author: @snarkbe The upload to gmcmap.com does not work anymore. journalctl shows ``` Apr 21 09:34:35 pihole gclog[30652]: CPM: 28 (= 1662/60), Timestamp: Sun Apr 21 07:33:35 2019 Apr 21 09:34:36 pihole gclog[30652]: [WARNING] Upload to gmcmap.com failed. ``` When I try to simulate an upload from command-line, I get: ``` $ curl -v "www.gmcmap.com/log2.asp?AID=01234&GID=1234567890&CPM=33" * Trying 184.168.224.226... * TCP_NODELAY set * Connected to www.gmcmap.com (184.168.224.226) port 80 (#0) > GET /log2.asp?AID=01234&GID=1234567890&CPM=33 HTTP/1.1 > Host: www.gmcmap.com > User-Agent: curl/7.52.1 > Accept: */* > < HTTP/1.1 301 Moved Permanently < Content-Type: text/html; charset=UTF-8 < Location: https://www.gmcmap.com/log2.asp?AID=01234&GID=1234567890&CPM=33 < Server: Microsoft-IIS/8.0 < X-Powered-By: ASP.NET < X-Powered-By-Plesk: PleskWin < Date: Sun, 21 Apr 2019 07:36:56 GMT < Content-Length: 194 < <head><title>Document Moved</title></head> * Curl_http_done: called premature == 0 * Connection #0 to host www.gmcmap.com left intact <body><h1>Object Moved</h1>This document may be found <a HREF="https://www.gmcmap.com/log2.asp?AID=01234&amp;GID=1234567890&amp;CPM=33">here</a></body> ``` So it looks like they're now redirecting all requests to https, which is not supported by the code in gclog.c .
Author
Owner

Author: @snarkbe

Other people are discussing vaguely similar issues at the GQ forum

Either the forced upgrade to https was not planned, or they have not measured the consequences.

Author: @snarkbe Other people are discussing vaguely similar issues at the [GQ forum](https://www.gqelectronicsllc.com/forum/topic.asp?TOPIC_ID=6905) Either the forced upgrade to https was not planned, or they have not measured the consequences.
Author
Owner

Author: @stelas

HTTPS support has been on the todo list for a year now. :(

The easiest way would be to use libcurl instead of the simple TCP client tcpcli.h. But that would break the compatibility with 4MB flash OpenWrt routers.

Author: @stelas HTTPS support has been on the todo list for a year now. :( The easiest way would be to use [libcurl](https://curl.haxx.se/libcurl/) instead of the simple TCP client ```tcpcli.h```. But that would break the compatibility with 4MB flash OpenWrt routers.
Author
Owner

Author: @snarkbe

I understand. But if they keep the redirect to https, it won't work anymore for all supported plaftorms, not only for OpenWrt.

Author: @snarkbe I understand. But if they keep the redirect to https, it won't work anymore for all supported plaftorms, not only for OpenWrt.
Author
Owner

Author: @stelas

I'll see how complex it is to write a wrapper for mbed TLS and integrate it. But that will take a while...

Author: @stelas I'll see how complex it is to write a wrapper for [mbed TLS](https://tls.mbed.org/kb/how-to/mbedtls-tutorial) and integrate it. But that will take a while...
Author
Owner

Author: @snarkbe

While it'll be nice to have https included later, it's not urgent. GQ has reckoned there was an issue at their side:

Sorry guys we are trying to fix the issues. Looks like https problem.

Author: @snarkbe While it'll be nice to have https included later, it's not urgent. [GQ has reckoned](https://www.gqelectronicsllc.com/forum/topic.asp?TOPIC_ID=6905) there was an issue at their side: > Sorry guys we are trying to fix the issues. Looks like https problem.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: steffen/GCLog#2
No description provided.