tor  master
Data Fields
directory_token_t Struct Reference

#include <parsecommon.h>

Collaboration diagram for directory_token_t:
Collaboration graph
[legend]

Data Fields

directory_keyword tp
 
int n_args:30
 
char ** args
 
char * object_type
 
size_t object_size
 
char * object_body
 
crypto_pk_tkey
 
char * error
 

Detailed Description

Structure to hold a single directory token.

We parse a directory by breaking it into "tokens", each consisting of a keyword, a line full of arguments, and a binary object. The arguments and object are both optional, depending on the keyword type.

This structure is only allocated in memareas; do not allocate it on the heap, or token_clear() won't work.

Field Documentation

◆ args

char** args

Array of arguments from keyword line.

◆ error

char* error

For ERR_ tokens only.

◆ key

For public keys only. Heap-allocated.

◆ n_args

int n_args

Number of elements in args

◆ object_body

char* object_body

Contents of object, base64-decoded.

◆ object_size

size_t object_size

Bytes in object_body

◆ object_type

char* object_type

--—BEGIN [object_type]--—

◆ tp

Type of the token.


The documentation for this struct was generated from the following file: