blob: 0fcf032ba0d6b9a7f491e09021306ec87d06584a [file] [log] [blame]
Jeff Thompson8238d002013-07-10 11:56:49 -07001/**
Jeff Thompson7687dc02013-09-13 11:54:07 -07002 * Copyright (C) 2013 Regents of the University of California.
3 * @author: Jeff Thompson <jefft0@remap.ucla.edu>
Jeff Thompson8238d002013-07-10 11:56:49 -07004 * See COPYING for copyright and distribution information.
5 */
6
7#ifndef NDN_PUBLISHERPUBLICKEYDIGEST_H
Jeff Thompson2d27e2f2013-08-09 12:55:00 -07008#define NDN_PUBLISHERPUBLICKEYDIGEST_H
Jeff Thompson8238d002013-07-10 11:56:49 -07009
Jeff Thompson2d27e2f2013-08-09 12:55:00 -070010#ifdef __cplusplus
Jeff Thompson8238d002013-07-10 11:56:49 -070011extern "C" {
12#endif
13
14/**
15 * A PublisherPublicKeyDigest holds a pointer to the publisher public key digest value, if any.
16 * We make a separate struct since this is used by multiple other structs.
17 */
18struct ndn_PublisherPublicKeyDigest {
Jeff Thompson2d27e2f2013-08-09 12:55:00 -070019 unsigned char *publisherPublicKeyDigest; /**< pointer to pre-allocated buffer. 0 for none */
Jeff Thompson8238d002013-07-10 11:56:49 -070020 unsigned int publisherPublicKeyDigestLength; /**< length of publisherPublicKeyDigest. 0 for none */
21};
22
23/**
24 * Initialize an ndn_PublisherPublicKeyDigest struct with 0 for none.
25 */
Jeff Thompsond1427fb2013-08-29 17:20:32 -070026static inline void ndn_PublisherPublicKeyDigest_initialize(struct ndn_PublisherPublicKeyDigest *self)
Jeff Thompson8238d002013-07-10 11:56:49 -070027{
28 self->publisherPublicKeyDigest = 0;
29 self->publisherPublicKeyDigestLength = 0;
30}
31
Jeff Thompson2d27e2f2013-08-09 12:55:00 -070032#ifdef __cplusplus
Jeff Thompson8238d002013-07-10 11:56:49 -070033}
34#endif
35
36#endif