N900 GPS Proxy

(Notes)
m
 
(2 intermediate revisions not shown)
Line 1: Line 1:
-
As of 2019, supl.nokia.com is not working, thus the N900 cannot get GPS assistance information. On the other hand, the N900 is also unable to communicate with Google's supl server, supl.google.com. So getting a GPS fix can take a very long time as there is no network assistance.
+
As of 2019, supl.nokia.com is not working, thus the N900 cannot get GPS assistance information. So getting a GPS fix can take a very long time as there is no network assistance.
 +
 
 +
Some are able to use Google's supl server directly, while for others it does not work. Even if it works for you out of the box, you might care about [https://blog.wirelessmoves.com/2014/08/supl-reveals-my-identity-and-location-to-google.html privacy concerns.]
The use of an A-GPS proxy, such as [https://www.tajuma.com/supl/index.html https://www.tajuma.com/supl/index.html] can get around the problem. It is already [http://maemo.org/packages/view/supl/ packaged], and available from Extras-Devel (you can temporarily enable -devel, then disable it afterwards)
The use of an A-GPS proxy, such as [https://www.tajuma.com/supl/index.html https://www.tajuma.com/supl/index.html] can get around the problem. It is already [http://maemo.org/packages/view/supl/ packaged], and available from Extras-Devel (you can temporarily enable -devel, then disable it afterwards)
-
 
-
edit: It has been found out supl.google.com can be used:
 
-
 
-
*In '''Settings > Connectivity > Location > Network Positioning''', replace supl.nokia.com with supl.google.com
 
-
*Find the supl.google.com IP near to you by looking [https://www.whatsmydns.net/#A/supl.google.com https://www.whatsmydns.net/#A/supl.google.com]
 
-
*In /etc/hosts, fill one line with the IP you found, one space and "supl.google.com"
 
-
*May be optionnal, to confirm: get the certificate for supl.google.com: [https://censys.io/certificates/95c074e35902a14abd9d19afb6e7f80e669ff8e2363270539d963613f04aaa21/pem], put it in /etc/certs/common-ca/ and test it with
 
-
<pre>openssl s_client -connect supl.google.com:7275 -CApath /etc/certs/common-ca/</pre>
 
-
 
-
*Reboot and control that the '''Settings > Connectivity > Location > Network Positioning''' setting survived the reboot (sometimes comming back to nokia in my N900)
 
-
 
-
However this is working, you might care about [https://blog.wirelessmoves.com/2014/08/supl-reveals-my-identity-and-location-to-google.html privacy concerns], then examine the possibility to use the proxy as explained below.
 
==Configuration==
==Configuration==
Line 23: Line 13:
<pre>
<pre>
~$ mkdir supl && cd supl/
~$ mkdir supl && cd supl/
-
~/supl$ supl-cert supl.fremantle.com
+
~/supl$ supl-cert supl.maemo-fremantle.com
</pre>
</pre>
* Install the CA certificate via cmcli:
* Install the CA certificate via cmcli:
Line 37: Line 27:
==Use==
==Use==
-
* Start the proxy and point it to supl.google.com (or any other supl server you know works):
+
* Connect the N900 to the internet with mobile network (wifi seems not to work).
 +
* Start the proxy and point it to supl.google.com (or any other supl server you know works, some are listed here: [https://www.reddit.com/r/privacy/comments/cldrym/how_to_degoogle_lineageos_in_2019/ https://www.reddit.com/r/privacy/comments/cldrym/how_to_degoogle_lineageos_in_2019/] ):
<pre>
<pre>
~$ cd supl/
~$ cd supl/
Line 43: Line 34:
</pre>
</pre>
* Run your GPS consumer application
* Run your GPS consumer application
-
If all went well, you should see a lot of output from the proxy, after which it will exit. Hopefully you get a fix in a few seconds.
+
If all went well, you should see a lot of output from the proxy, after which it will exit. Hopefully you will get a fix in a few seconds.
==Notes==
==Notes==
Line 55: Line 46:
*You can use [https://bugs.maemo.org/show_bug.cgi?id=7026#c35 this tool] to clear the GPS cache which may induce wrong conclusions about last changes/test.
*You can use [https://bugs.maemo.org/show_bug.cgi?id=7026#c35 this tool] to clear the GPS cache which may induce wrong conclusions about last changes/test.
*You can use [http://maemo.org/packages/view/location-test-gui/ location-test-gui] to test your gps/a-gps.
*You can use [http://maemo.org/packages/view/location-test-gui/ location-test-gui] to test your gps/a-gps.
-
*It may not always work with wifi connection. In this case, try gprs internet connection.
+
*It may not always work with a wifi connection. In this case, try a gprs internet connection.
-
For further informations, search the forum for threads like [https://talk.maemo.org/showthread.php?t=90651&page=30 this one]
+
For further information, search the forum for threads like [https://talk.maemo.org/showthread.php?t=90651&page=30 this one]
Please update this wiki with your observations.
Please update this wiki with your observations.

Latest revision as of 06:30, 2 December 2019

As of 2019, supl.nokia.com is not working, thus the N900 cannot get GPS assistance information. So getting a GPS fix can take a very long time as there is no network assistance.

Some are able to use Google's supl server directly, while for others it does not work. Even if it works for you out of the box, you might care about privacy concerns.

The use of an A-GPS proxy, such as https://www.tajuma.com/supl/index.html can get around the problem. It is already packaged, and available from Extras-Devel (you can temporarily enable -devel, then disable it afterwards)

[edit] Configuration

After installation of supl on the N900, you can perform the following steps:

  • Choose a subdomain for the certificates you will create. The subdomain needs to conform to the general rules for domain names, and have a valid TLD. It does not necessarily need to exist however, but it is a good idea to use a domain that you have control of or which does not exist somewhere else or belongs to somebody else. For our example, we will use supl.maemo-fremantle.com which is not used at the time of writing.
  • Create the certificates on the device. Since the proxy needs to find the certificates in the current working directory, it is also a good idea to create a specific directory for this purpose:
~$ mkdir supl && cd supl/
~/supl$ supl-cert supl.maemo-fremantle.com
  • Install the CA certificate via cmcli:
~/supl$ sudo cmcli -c common-ca -a ca-cert.pem
  • Edit the "Location server" field in Settings > Connectivity > Location > Network Positioning to point to the subdomain you chose earlier (supl.maemo-fremantle.com)
  • If you used a non-existent domain name, edit /etc/hosts to resolve its IP, e.g. add the following:
127.0.0.1  supl.maemo-fremantle.com
  • Reboot the device (otherwise the proxy will fail the certificates check)
  • Verify the "Location server" field in Settings > Connectivity > Location > Network Positioning after reboot as it seems to come back to nokia sometimes.

[edit] Use

~$ cd supl/
~/supl$ supl-proxy supl.google.com
  • Run your GPS consumer application

If all went well, you should see a lot of output from the proxy, after which it will exit. Hopefully you will get a fix in a few seconds.

[edit] Notes

  • As is, the supl proxy will exit after one successful transaction
  • If you did not get a fix, and there were no errors from the proxy, you will likely find that the device will not make another supl request even if the proxy is running. You can try the following:
~$ sudo stop location-proxy
~$ sudo start location-proxy
  • Also, it seems that a new supl request can be issued after a change in CellID, so moving to a different location may help.
  • You can use this tool to clear the GPS cache which may induce wrong conclusions about last changes/test.
  • You can use location-test-gui to test your gps/a-gps.
  • It may not always work with a wifi connection. In this case, try a gprs internet connection.

For further information, search the forum for threads like this one

Please update this wiki with your observations.