I'm designing a very simple data collection device for a research project. Because we are logging, among other stuff, the GPS position of actual vehicles, we need to protect the data. Since we manually deploy every logging device, there is no need for registrations or logins.
I have set up a web server (Node.js), a database (MongoDB), an app (native iOS), and a data format (JSON). The client regularly sends JSON to the web server with the following command:
PUT/store/[deviceId]/?hash=[hash]
(with the actual data as a POST variable)
Where the deviceId is a simple identifier, for now just a number (0, 1 or 2), to make me choose which MongoDB collection to store the data in.
The hash is a hash of the HTTP verb, the url, and the device's secret (just a random string hard-coded into each device), inspired by this answer.
My concern here is how secure such a system is. I am using HTTPS to protect the data transfer, and the device secret to make sure it's actually one of our devices, and not the neighbor's son trying to hack us.
Is that enough?
As can be seen, if you enumerate all vectors, you're left with a certain amount of tasks that have to be looked into. If you're up against your neighbour's son, just a simple https should be enough as long as you don't have that freak protocol degrade problem on your server.
– munchkin Mar 05 '15 at 12:12