Mobile App Error: Invalid signature - SecurityException (CryptoManager:76 < TokenManager:77 < LoginService:81 < ...)

Duncan Miller4 months ago

I am new to Traccar and I have done a two clean installs on Ubuntu and a Docker Install all with the same results. Every time I use the Traccar Manager app on iOS to connect to my install the app throws an error message:

"Invalid signature - SecurityException (CryptoManager:76 < TokenManager:77 < LoginService:81 < ...)"

I don't see anything in the error logs. Anyone have an idea why this is happening? Thanks in advance.

IMG_D5FDC65951C4-1.jpeg

Anton Tananaev4 months ago

Have you logged in? What are the steps to reproduce from clean installation of the server and the app?

Duncan Miller4 months ago

It looks to be an issue with the app on my one phone. I have now tested it on two additional iPhone and the app works without issue.

I have deleted the app and re installed it twice now and still the same issue.

Phone with Issue - iOS Version 17.5.1, iPhone 15 Pro

No Issue - iOS Version 17.5.1, iPhone SE
No Issue - iOS Version 15.3, iPhone XS Max

Duncan Miller4 months ago

If I disable my passcode and FaceID on my iPhone the error is no longer present.

Duncan Miller4 months ago

Does the Traccar app support FaceID?

On my iPhone 15 Pro it supported Face ID to unlock the app however now it no longer does after I disabled Face ID and re enabled it in iOS. This issue has also resolved itself now.

My other two phones never had Face ID enabled.

Anton Tananaev4 months ago

Are you planning to answer my earlier question?

Duncan Miller4 months ago

The error happens without even logging into the server.

I did 3 different installs as follows

Ubuntu 22.04LTS and the default H2 Database
Ubuntu 24.04LTS and the default H2 Database
Ubuntu 24.04LTS and mysql Database
Ubuntu 24.04LTS with Docker

Config is below

<properties>

     <!-- DATABASE H2 -->

    <entry key='database.driver'>org.h2.Driver</entry>
    <entry key='database.url'>jdbc:h2:./data/database</entry>
    <entry key='database.user'>sa</entry>
    <entry key='database.password'></entry>
    
    
    <!-- DATABASE MYSQL -->

    <entry key='database.driver'>com.mysql.cj.jdbc.Driver</entry>
    <entry key='database.url'>jdbc:mysql://localhost/traccar?zeroDateTimeBehavior=round&amp;serverTimezone=UTC&amp;allowPublicKeyRetrieval=true&amp;useSSL=false&amp;allowMultiQueries=true&amp;autoReconnect=true&amp;useUnicode=yes&amp;characterEncoding=UTF-8&amp;sessionVariables=sql_mode=''</entry>
    <entry key='database.user'>root</entry>
    <entry key='database.password'>****</entry>
 
 
    <!-- SERVER CONFIG -->

    <entry key='web.enable'>true</entry>
    <entry key='web.port'>80</entry>
    <entry key='web.path'>./web</entry>
    

    <!-- NOTIFICATION CONFIG -->

    <entry key='notificator.types'>web,mail,traccar,sms</entry>
    <entry key='sms.http.url'>https://api.twilio.com/2010-04-01/Accounts/****/Messages.json</entry>
    <entry key='sms.http.user'>****</entry>
    <entry key='sms.http.password'>****</entry>
    <entry key='sms.http.template'>From=+18252548273&amp;To={phone}&amp;Body={message}</entry>
    <entry key='notificator.traccar.key'>****</entry>

</properties>
Anton Tananaev4 months ago

This error cannot happen without logging in.

Duncan Miller4 months ago

The install has no devices or any configuration other than basic Time Zone configuration and user configuration.

The server URL was set in the app and that's when the error happened. So there was communication with the server after the URL is set I take it?

Anton Tananaev4 months ago

Did you login to another server before changing URL? That would explain the issue. Your login token would be for the old server.

Duncan Miller4 months ago

Got it. Thanks. Anyway to clear the token?

It's not doing it anymore so it's not really a problem but just for curiosity sakes.

Anton Tananaev4 months ago

You can just login into the new server and it should save the new token.

Saglam3 months ago
<entry key='database.driver'>org.h2.Driver</entry>
<entry key='database.url'>jdbc:h2:./data/database</entry>
<entry key='database.user'>sa</entry>
<entry key='database.password'></entry>




<entry key='database.driver'>com.mysql.cj.jdbc.Driver</entry>
<entry key='database.url'>jdbc:mysql://localhost/traccar?zeroDateTimeBehavior=round&serverTimezone=UTC&allowPublicKeyRetrieval=true&useSSL=false&allowMultiQueries=true&autoReconnect=true&useUnicode=yes&characterEncoding=UTF-8&sessionVariables=sql_mode=''</entry>
<entry key='database.user'>root</entry>
<entry key='database.password'>****</entry>

It doesn't seem right to define two different database types in the same config file like this.