joylink_crypt.h 415 B

1234567891011121314151617181920
  1. #ifndef _NODECACHE_H
  2. #define _NODECACHE_H
  3. #include "joylink.h"
  4. #include "joylink_aes.h"
  5. typedef struct {
  6. int isInited;
  7. uint8_t priKey[uECC_BYTES];
  8. uint8_t devPubKey[uECC_BYTES * 2];
  9. uint8_t devPubKeyC[uECC_BYTES + 1];
  10. }JLEccContex_t;
  11. typedef struct{
  12. uint8_t pubkeyC[JL_MAX_KEY_BIN_LEN]; // ѹ????ʽ?Ĺ?Կ
  13. uint8_t sharedkey[uECC_BYTES]; // ?豸?Ĺ?????Կ
  14. }JLKey_t;
  15. extern JLEccContex_t __g_ekey;
  16. #endif