25'ten fazla konu seçemezsiniz Konular bir harf veya rakamla başlamalı, kısa çizgiler ('-') içerebilir ve en fazla 35 karakter uzunluğunda olabilir.
 
 

40 satır
1.0 KiB

  1. #ifndef XMSS_HASH_ADDRESS_H
  2. #define XMSS_HASH_ADDRESS_H
  3. #include <stdint.h>
  4. #define XMSS_ADDR_TYPE_OTS 0
  5. #define XMSS_ADDR_TYPE_LTREE 1
  6. #define XMSS_ADDR_TYPE_HASHTREE 2
  7. void set_layer_addr(uint32_t addr[8], uint32_t layer);
  8. void set_tree_addr(uint32_t addr[8], uint64_t tree);
  9. void set_type(uint32_t addr[8], uint32_t type);
  10. void set_key_and_mask(uint32_t addr[8], uint32_t key_and_mask);
  11. /* Copies the layer and tree part of one address into the other */
  12. void copy_subtree_addr(uint32_t out[8], const uint32_t in[8]);
  13. /* These functions are used for OTS addresses. */
  14. void set_ots_addr(uint32_t addr[8], uint32_t ots);
  15. void set_chain_addr(uint32_t addr[8], uint32_t chain);
  16. void set_hash_addr(uint32_t addr[8], uint32_t hash);
  17. /* This function is used for L-tree addresses. */
  18. void set_ltree_addr(uint32_t addr[8], uint32_t ltree);
  19. /* These functions are used for hash tree addresses. */
  20. void set_tree_height(uint32_t addr[8], uint32_t tree_height);
  21. void set_tree_index(uint32_t addr[8], uint32_t tree_index);
  22. #endif