public async Task <object> PostValidateKeyAsync([FromBody] KeyAuth key) { Keycode _keycode = await db.Keycodes.FindAsync(key.keyCode); if (_keycode == null || _keycode.TokenId != key.tokenId) { return(null); } //Key can be registered. //For debugging, simply return the keycode for now return(_keycode); }
public TestDevice(string genId, KeyAuth auth) { this.GenId = genId; this.Auth = auth; }