I also posted this thread on Unity's forum, but as it's more server/crypto oriented I'll ask here aswell.
As mentionned in the title, I'm using unity as a client, and connect to a nodeJS server using socket.io (with BestHTTP asset).
What I want to achieve : user1 get a license key (by email or w/e) that was signed by my server, enter the key in the app, client ask the server if the key is valid and has been signed, and if so user1's computer can play. This will only require an internet connexion when "registering" the license key, and then I'd store the key in a hashed file or something so user1 can play without contacting the server everytime. Simplified version : user1 only need to be connected once (the first time he launch the app), but I need to check at every launch if he's allowed to play.
Client-side (in Unity c#) is working fine, what I do is basically hashing the key and storing it in a file, then hashing that file to verify users don't modify it.
But then, I don't know what to do on server-side. Are there API that can achieve what I want to do ? Am I going in a wrong direction ? That's the first time I'm dealing with crypto, and I'm a bit lost :confused:
Any help would be greatly appreciated !