A network including an optical sensing device and a registration server:
wherein a secret key and a public unique identifier are installed in a
non-volatile memory of the optical sensing device and in a database of
the registration server, before the optical sensing device is connected
to the network; wherein, the registration server is adapted to
authenticate the optical sensing device when the optical sensing device
is connected to the network by verifying the optical sensing device's
encryption, using the secret key, of a challenge message; wherein, if the
authentication succeeds, the optical sensing device is registered in the
database of the registration server; and wherein the optical sensing
device is adapted to capture a sequence of time-stamped positions of the
optical sensing device relative to a surface including coded data.