How to authenticate client application for trust of messages sent from it

后端 未结 3 381
忘了有多久
忘了有多久 2020-12-10 22:03

The basic question
How do I know that it is my publicly accessible (client) application that is sending my service messages? How do I know that it is j

3条回答
  •  天涯浪人
    2020-12-10 22:19

    Impossible.

    You can authenticate users, but not the application.

    Let's say you decide to digitally sign the application. This signature is then read at runtime by your client application checking its own executable binaries against this signature. There is nothing that prevents the adversary from simply removing this check from your application.

    Even if you make it close to impossible to reverse engineer your application, the adversary could always look at the communication channel and write an imposter that looks indistinguishable from your client to your server.

    The only thing you can do is validate the actions on the server against a user identity.

提交回复
热议问题