solo1/fido2/extensions/extensions.h

30 wiersze
991 B
C

2019-02-12 22:18:17 +00:00
// Copyright 2019 SoloKeys Developers
//
// Licensed under the Apache License, Version 2.0, <LICENSE-APACHE or
// http://apache.org/licenses/LICENSE-2.0> or the MIT license <LICENSE-MIT or
// http://opensource.org/licenses/MIT>, at your option. This file may not be
// copied, modified, or distributed except according to those terms.
2018-09-13 02:32:15 +00:00
#ifndef EXTENSIONS_H_
#define EXTENSIONS_H_
#include "u2f.h"
2019-02-26 20:30:57 +00:00
#include "apdu.h"
2018-09-13 02:32:15 +00:00
2019-04-24 01:57:50 +00:00
int16_t bridge_u2f_to_extensions(uint8_t * chal, uint8_t * appid, uint8_t klen, uint8_t * keyh);
// return 1 if request is a wallet request
int is_extension_request(uint8_t * req, int len);
2019-02-26 20:30:57 +00:00
int16_t extend_u2f(APDU_HEADER * req, uint8_t * payload, uint32_t len);
2018-09-13 02:32:15 +00:00
2019-02-14 20:15:58 +00:00
int16_t extend_fido2(CredentialId * credid, uint8_t * output);
int bootloader_bridge(int klen, uint8_t * keyh);
2018-12-04 01:06:44 +00:00
2019-02-14 20:15:58 +00:00
int is_extension_request(uint8_t * kh, int len);
2019-04-24 01:57:50 +00:00
void extension_writeback_init(uint8_t * buffer, uint8_t size);
void extension_writeback(uint8_t * buf, uint8_t size);
2018-09-13 02:32:15 +00:00
#endif /* EXTENSIONS_H_ */