Add the token issuer web service

The token issuer is implemented as a Firebase Cloud Function. The
function issues JsonWebSignatures using RS256.

Only authenticated users can get a token. This is done by checking the
`context.auth` property of each incoming request.

The API takes a `nonce` and a `deviceId` as inputs for now; but it can
be easily extended in case more fine-grained control is needed.

See more details in `server/HOW_TO.md`.

Bug: 173734542
Bug: 173734533
Bug: 173734974
Bug: 180963653
Test: npm install -g firebase-tools
Test: firebase emulators:start --only functions
Change-Id: Ibfc1978ef0cb42bad8867b2e202afe608a55c4ad
10 files changed