[hipl-commit] [trunk] Rev 4284: Move most of the contents of doc/doxygen.h into source files.

  • From: Diego Biurrun <diego@xxxxxxxxxx>
  • To: hipl-commit@xxxxxxxxxxxxx
  • Date: Wed, 14 Apr 2010 21:53:10 +0300

Committer: Diego Biurrun <diego@xxxxxxxxxx>
Date: 14/04/2010 at 21:53:09
Revision: 4284
Revision-id: diego@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Branch nick: trunk

Log:
  Move most of the contents of doc/doxygen.h into source files.
  
  This makes the documentation directly available where it is needed.
  Plus, updating it will not be forgotten. There was already some
  documentation for nonexisting code left; now it is removed.

Modified:
  M  doc/doxygen.h
  M  hipd/accessor.h
  M  hipd/input.c
  M  lib/conf/hipconf.h
  M  lib/core/builder.c
  M  lib/core/debug.h
  M  lib/core/icomm.h
  M  lib/core/protodefs.h
  M  lib/core/state.h
  M  lib/gui/hipgui.h

=== modified file 'doc/doxygen.h'
--- doc/doxygen.h       2010-03-29 17:47:36 +0000
+++ doc/doxygen.h       2010-04-14 18:51:38 +0000
@@ -120,411 +120,6 @@
  */
 
 /**
- * Error handling macros used for checking errors. To use these macros, define 
a
- * label named @c out_err at the end of the function. For example, memory
- * allocation/deallocation procedure is as follows:
- * <pre>
- * int f(void)
- * {
- *     char *mem = NULL;
- *     HIP_IFEL(!(mem = HIP_ALLOC(256, 0)), -1, "alloc\n");
- *
- * out_err:
- *     if (mem != NULL) {
- *         free(mem);
- *     }
- *     return err;
- * }
- * </pre>
- * All functions should return an error value instead of "ok" value. That, is
- * zero for success and non-zero for failure. Error values are defined in
- * /usr/include/asm-generic/errno-base.h and /usr/include/asm-generic/errno.h
- * as follows:
- *
- * <pre>
- * EPERM            1       Operation not permitted
- * ENOENT           2       No such file or directory
- * ESRCH            3       No such process
- * EINTR            4       Interrupted system call
- * EIO              5       I/O error
- * ENXIO            6       No such device or address
- * E2BIG            7       Argument list too long
- * ENOEXEC          8       Exec format error
- * EBADF            9       Bad file number
- * ECHILD          10       No child processes
- * EAGAIN          11       Try again
- * ENOMEM          12       Out of memory
- * EACCES          13       Permission denied
- * EFAULT          14       Bad address
- * ENOTBLK         15       Block device required
- * EBUSY           16       Device or resource busy
- * EEXIST          17       File exists
- * EXDEV           18       Cross-device link
- * ENODEV          19       No such device
- * ENOTDIR         20       Not a directory
- * EISDIR          21       Is a directory
- * EINVAL          22       Invalid argument
- * ENFILE          23       File table overflow
- * EMFILE          24       Too many open files
- * ENOTTY          25       Not a typewriter
- * ETXTBSY         26       Text file busy
- * EFBIG           27       File too large
- * ENOSPC          28       No space left on device
- * ESPIPE          29       Illegal seek
- * EROFS           30       Read-only file system
- * EMLINK          31       Too many links
- * EPIPE           32       Broken pipe
- * EDOM            33       Math argument out of domain of func
- * ERANGE          34       Math result not representable
- * EDEADLK         35       Resource deadlock would occur
- * ENAMETOOLONG    36       File name too long
- * ENOLCK          37       No record locks available
- * ENOSYS          38       Function not implemented
- * ENOTEMPTY       39       Directory not empty
- * ELOOP           40       Too many symbolic links encountered
- * EWOULDBLOCK     EAGAIN   Operation would block
- * ENOMSG          42       No message of desired type
- * EIDRM           43       Identifier removed
- * ECHRNG          44       Channel number out of range
- * EL2NSYNC        45       Level 2 not synchronized
- * EL3HLT          46       Level 3 halted
- * EL3RST          47       Level 3 reset
- * ELNRNG          48       Link number out of range
- * EUNATCH         49       Protocol driver not attached
- * ENOCSI          50       No CSI structure available
- * EL2HLT          51       Level 2 halted
- * EBADE           52       Invalid exchange
- * EBADR           53       Invalid request descriptor
- * EXFULL          54       Exchange full
- * ENOANO          55       No anode
- * EBADRQC         56       Invalid request code
- * EBADSLT         57       Invalid slot
- * EDEADLOCK       EDEADLK
- * EBFONT          59       Bad font file format
- * ENOSTR          60       Device not a stream
- * ENODATA         61       No data available
- * ETIME           62       Timer expired
- * ENOSR           63       Out of streams resources
- * ENONET          64       Machine is not on the network
- * ENOPKG          65       Package not installed
- * EREMOTE         66       Object is remote
- * ENOLINK         67       Link has been severed
- * EADV            68       Advertise error
- * ESRMNT          69       Srmount error
- * ECOMM           70       Communication error on send
- * EPROTO          71       Protocol error
- * EMULTIHOP       72       Multihop attempted
- * EDOTDOT         73       RFS specific error
- * EBADMSG         74       Not a data message
- * EOVERFLOW       75       Value too large for defined data type
- * ENOTUNIQ        76       Name not unique on network
- * EBADFD          77       File descriptor in bad state
- * EREMCHG         78       Remote address changed
- * ELIBACC         79       Can not access a needed shared library
- * ELIBBAD         80       Accessing a corrupted shared library
- * ELIBSCN         81       .lib section in a.out corrupted
- * ELIBMAX         82       Attempting to link in too many shared libraries
- * ELIBEXEC        83       Cannot exec a shared library directly
- * EILSEQ          84       Illegal byte sequence
- * ERESTART        85       Interrupted system call should be restarted
- * ESTRPIPE        86       Streams pipe error
- * EUSERS          87       Too many users
- * ENOTSOCK        88       Socket operation on non-socket
- * EDESTADDRREQ    89       Destination address required
- * EMSGSIZE        90       Message too long
- * EPROTOTYPE      91       Protocol wrong type for socket
- * ENOPROTOOPT     92       Protocol not available
- * EPROTONOSUPPORT 93       Protocol not supported
- * ESOCKTNOSUPPORT 94       Socket type not supported
- * EOPNOTSUPP      95       Operation not supported on transport endpoint
- * EPFNOSUPPORT    96       Protocol family not supported
- * EAFNOSUPPORT    97       Address family not supported by protocol
- * EADDRINUSE      98       Address already in use
- * EADDRNOTAVAIL   99       Cannot assign requested address
- * ENETDOWN        100      Network is down
- * ENETUNREACH     101      Network is unreachable
- * ENETRESET       102      Network dropped connection because of reset
- * ECONNABORTED    103      Software caused connection abort
- * ECONNRESET      104      Connection reset by peer
- * ENOBUFS         105      No buffer space available
- * EISCONN         106      Transport endpoint is already connected
- * ENOTCONN        107      Transport endpoint is not connected
- * ESHUTDOWN       108      Cannot send after transport endpoint shutdown
- * ETOOMANYREFS    109      Too many references: cannot splice
- * ETIMEDOUT       110      Connection timed out
- * ECONNREFUSED    111      Connection refused
- * EHOSTDOWN       112      Host is down
- * EHOSTUNREACH    113      No route to host
- * EALREADY        114      Operation already in progress
- * EINPROGRESS     115      Operation now in progress
- * ESTALE          116      Stale NFS file handle
- * EUCLEAN         117      Structure needs cleaning
- * ENOTNAM         118      Not a XENIX named type file
- * ENAVAIL         119      No XENIX semaphores available
- * EISNAM          120      Is a named type file
- * EREMOTEIO       121      Remote I/O error
- * EDQUOT          122      Quota exceeded
- * ENOMEDIUM       123      No medium found
- * EMEDIUMTYPE     124      Wrong medium type
- * ECANCELED       125      Operation Canceled
- * ENOKEY          126      Required key not available
- * EKEYEXPIRED     127      Key has expired
- * EKEYREVOKED     128      Key has been revoked
- * EKEYREJECTED    129      Key was rejected by service
- * EOWNERDEAD      130      Owner died
- * ENOTRECOVERABLE 131      State not recoverable
- * </pre>
- * Following error values are defined in /usr/include/netdb.h:
- * <pre>
- * NETDB_INTERNAL  -1       See errno.
- * NETDB_SUCCESS   0        No problem.
- * HOST_NOT_FOUND  1        Authoritative Answer Host not found.
- * TRY_AGAIN       2        Non-Authoritative Host not found, or SERVERFAIL.
- * NO_RECOVERY     3        Non recoverable errors, FORMERR, REFUSED,NOTIMP.
- * NO_DATA         4        Valid name, no data record of requested type.
- * NO_ADDRESS      NO_DATA  No address, look for MX record.
- * EKEYREJECTED    129      Key was rejected by service
- * EOWNERDEAD      130      Owner died
- * ENOTRECOVERABLE 131      State not recoverable
- * </pre>
- * Following error values for `getaddrinfo' function are defined in
- * /usr/include/netdb.h:
- * <pre>
- * EAI_BADFLAGS    -1       Invalid value for `ai_flags' field.
- * EAI_NONAME      -2       NAME or SERVICE is unknown.
- * EAI_AGAIN       -3       Temporary failure in name resolution.
- * EAI_FAIL        -4       Non-recoverable failure in name res.
- * EAI_NODATA      -5       No address associated with NAME.
- * EAI_FAMILY      -6       `ai_family' not supported.
- * EAI_SOCKTYPE    -7       `ai_socktype' not supported.
- * EAI_SERVICE     -8       SERVICE not supported for `ai_socktype'.
- * EAI_ADDRFAMILY  -9       Address family for NAME not supported.
- * EAI_MEMORY      -10      Memory allocation failure.
- * EAI_SYSTEM      -11      System error returned in `errno'.
- * EAI_OVERFLOW    -12      Argument buffer overflow.
- * </pre>
- *
- * @defgroup ife Error handling macros
- */
-
-/** @defgroup debug HIP debug macros
- *
- * Unfortunately Doxygen gets confused when dealing with the extensive '\' and
- * '#' characters that these macros contain. This documentation is therefore
- * messed up. You can find the implementation of these macros from 
lib/core/debug.h.
- */
-
-/** @defgroup params TODOs for parameters */
-
-/**
- * @defgroup hip_msg HIP daemon message types
- * @note Don't make these values higher than 255.
- *       The variable, which stores this type, is 8 bits.
- */
-
-/**
- * @file
- * @def HIP_I1
- * @def HIP_R1
- * @def HIP_I2
- * @def HIP_R2
- * @def HIP_CER
- * @def HIP_BOS
- * @note removed from ietf-hip-base-01.
- * @def HIP_UPDATE
- * @def HIP_NOTIFY
- * @def HIP_CLOSE
- * @def HIP_CLOSE_ACK
- * @def HIP_PSIG
- *      Lightweight HIP pre signature.
- * @def HIP_TRIG
- *      Lightweight HIP signature trigger.
- * @def HIP_PAYLOAD
- * @def HIP_AGENT_PING
- *      Agent can ping daemon with this message.
- * @def HIP_AGENT_PING_REPLY
- *      Daemon should reply to @c HIP_AGENT_PING with this one.
- * @def HIP_AGENT_QUIT
- *      Agent send this one to daemon when exiting.
- * @def HIP_ADD_DB_HI
- *      Daemon sends local HITs to agent with this message.
- * @def HIP_I1_REJECT
- *      Agent informs daemon about I1 rejection with this message.
- * @def HIP_UPDATE_HIU
- *      Daemon sends remote HITs in use with this message to agent.
- * @def HIP_FIREWALL_PING
- *      Firewall can ping daemon with this message.
- * @def HIP_FIREWALL_PING_REPLY
- *      Daemon should reply to @c HIP_FIREWALL_PING with this one.
- * @def HIP_FIREWALL_QUIT
- *      Firewall sends this one to daemon when exiting.
- * @def HIP_NAT_ON
- *      Daemon tells, that nat extension status changed.
- * @def HIP_NAT_OFF
- *      Daemon tells, that nat extension status changed.
- * @def HIP_DAEMON_QUIT
- *      Daemon should send this message to other processes, when quiting.
- *      Currently sending to: agent.
- */
-
-/** @defgroup hip_so HIP socket options */
-
-/** @defgroup libhipgui HIP GUI library */
-
-/** @defgroup daemon_states HIP daemon states */
-
-/** @defgroup exec_app_types Execute application types */
-
-/**
- * Type values used in Host Identity Protocol (HIP) parameters.
- *
- * These are the type values used in Host Identity Protocol (HIP) parameters
- * defined in [draft-ietf-hip-base] and other drafts expanding it. Because the
- * ordering (from lowest to highest) of HIP parameters is strictly enforced, 
the
- * parameter type values for existing parameters have been spaced to allow for
- * future protocol extensions.
- *
- * <b>Type values are grouped as follows:</b>
- * <ul>
- * <li>0-1023 are used in HIP handshake and update procedures and are covered
- * by signatures.</li>
- * <li>1024-2047 are reserved.</li>
- * <li>2048-4095 are used for parameters related to HIP transform types.</li>
- * <li>4096-61439 are reserved. However, a subset (32768 - 49141) of this can 
be
- * used for HIPL private parameters.</li>
- * <li>61440-62463 are used for signatures and signed MACs.</li>
- * <li>62464-63487 are used for parameters that fall outside of the signed area
- * of the packet.</li>
- * <li>63488-64511 are used for rendezvous and other relaying services.</li>
- * <li>64512-65535 are reserved.</li>
- * </ul>
- *
- * @defgroup hip_param_type_numbers HIP parameter type values
- * @see      hip_tlv
- * @see      hip_param_func
- * @see      <a 
href="http://hip4inter.net/documentation/drafts/draft-ietf-hip-base-06-pre180506.txt";>
- *           draft-ietf-hip-base-06-pre180506</a> section 5.2.
- * @note     The order of the parameters is strictly enforced. The parameters
- *           @b must be in order from lowest to highest.
- */
-
-/**
- * @file
- * @def HIP_PARAM_MIN
- *      Defines the minimum parameter type value.
- * @note exclusive
- * @def HIP_PARAM_ESP_INFO
- * @def HIP_PARAM_R1_COUNTER
- * @def HIP_PARAM_LOCATOR
- * @def HIP_PARAM_HASH_CHAIN_VALUE
- *      lhip hash chain. 221 is is temporary.
- * @def HIP_PARAM_HASH_CHAIN_ANCHORS
- *      lhip hash chain anchors. 222 is temporary.
- * @def HIP_PARAM_HASH_CHAIN_PSIG
- *      lhip hash chain signature. 223 is temporary.
- * @def HIP_PARAM_PUZZLE
- * @def HIP_PARAM_SOLUTION
- * @def HIP_PARAM_SEQ
- * @def HIP_PARAM_ACK
- * @def HIP_PARAM_DIFFIE_HELLMAN
- * @def HIP_PARAM_HIP_TRANSFORM
- * @def HIP_PARAM_ENCRYPTED
- * @def HIP_PARAM_HOST_ID
- * @def HIP_PARAM_CERT
- * @def HIP_PARAM_NOTIFICATION
- * @def HIP_PARAM_ECHO_REQUEST_SIGN
- * @def HIP_PARAM_ECHO_RESPONSE_SIGN
- * @def HIP_PARAM_ESP_TRANSFORM
- * @def HIP_PARAM_HIT
- * @def HIP_PARAM_IPV6_ADDR
- * @def HIP_PARAM_DSA_SIGN_DATA
- * @todo change to digest
- * @def HIP_PARAM_HI
- * @def HIP_PARAM_DH_SHARED_KEY
- * @def HIP_PARAM_UNIT_TEST
- * @def HIP_PARAM_EID_SOCKADDR
- * @def HIP_PARAM_EID_ENDPOINT
- *      Pass endpoint_hip structures into kernel.
- * @def HIP_PARAM_EID_IFACE
- * @def HIP_PARAM_EID_ADDR
- * @def HIP_PARAM_UINT
- *      Unsigned integer.
- * @def HIP_PARAM_KEYS
- * @def HIP_PARAM_PSEUDO_HIT
- * @def HIP_PARAM_REG_INFO
- * @def HIP_PARAM_REG_REQUEST
- * @def HIP_PARAM_REG_RESPONSE
- * @def HIP_PARAM_REG_FAILED
- * @def HIP_PARAM_BLIND_NONCE
- *      Pass blind nonce
- * @def HIP_PARAM_OPENDHT_GW_INFO
- * @def HIP_PARAM_ENCAPS_MSG
- * @def HIP_PARAM_PORTPAIR
- * @def HIP_PARAM_SRC_ADDR
- * @def HIP_PARAM_DST_ADDR
- * @def HIP_PARAM_AGENT_REJECT
- * @def HIP_PARAM_HA_INFO
- * @def HIP_PARAM_HMAC
- * @def HIP_PARAM_HMAC2
- * @def HIP_PARAM_HIP_SIGNATURE2
- * @def HIP_PARAM_HIP_SIGNATURE
- * @def HIP_PARAM_ECHO_RESPONSE
- * @def HIP_PARAM_ECHO_REQUEST
- * @def HIP_PARAM_RELAY_FROM
- *      HIP relay related parameter.
- * @note Former FROM_NAT.
- * @def HIP_PARAM_RELAY_TO
- *      HIP relay related parameter.
- * @note Former VIA_RVS_NAT
- * @def HIP_PARAM_FROM_PEER
- * @def HIP_PARAM_TO_PEER
- * @def HIP_PARAM_REG_FROM
- * @def HIP_PARAM_FROM
- * @def HIP_PARAM_RVS_HMAC
- * @def HIP_PARAM_VIA_RVS
- * @def HIP_PARAM_RELAY_HMAC
- *      HIP relay related parameter.
- * @def HIP_PARAM_MAX
- *      Defines the maximum parameter type value.
- * @note exclusive
- */
-
-/**
- * Type-length-value data structures in Host Identity Protocol (HIP).
- *
- * @defgroup hip_tlv HIP TLV data structures
- * @see      hip_param_type_numbers
- * @see      hip_param_func
- * @see      <a 
href="http://hip4inter.net/documentation/drafts/draft-ietf-hip-base-06-pre180506.txt";>
- *           draft-ietf-hip-base-06-pre180506</a> section 5.2.
- * @note     The order of the parameters is strictly enforced. The parameters
- *           @b must be in order from lowest to highest.
- */
-
-/**
- * HIP host assosiation function pointer data structures.
- *
- * Data structures containing function pointers pointing to functions used for
- * sending, receiving and handling data and modifying host assosiation state.
- *
- * @defgroup hadb_func HIP host assosiation function sets
- */
-
-/**
- * Functions for receiving HIP control packets.
- *
- * These functions are called after a HIP control packet is received by
- * hip_receive_control_packet()-function and the packet is detected to be a HIP
- * control packet. The purpose of these functions is to decide whether to
- * handle the packet at all. This decision is based first and foremost on the
- * state of the current host association. If the packet is to be handled, all
- * handling should be done in respective handle-function.
- *
- * @defgroup receive_functions HIP receive functions
- * @see      handle_functions
- */
-
-/**
  * Functions for handling HIP control packets.
  *
  * These functions do the actual handling of the packet. These functions are
@@ -542,265 +137,4 @@
  * @see      hip_tlv
  */
 
-/**
- * HIP NOTIFICATION parameter values.
- *
- * NOTIFICATION parameter error types used in the "Notify Message Type"-field 
of
- * NOTIFICATION parameter as specified in section 5.2.16. of
- * draft-ietf-hip-base-06.
- *
- * @defgroup notification NOTIFICATION parameter values
- * @see      hip_notification
- */
-
-/**
- * @file
- * @def  HIP_NTF_UNSUPPORTED_CRITICAL_PARAMETER_TYPE
- *       Sent if the parameter type has the "critical" bit set and the
- *       parameter type is not recognized.  Notification Data contains the two
- *       octet parameter type.
- * @def  HIP_NTF_INVALID_SYNTAX
- *       Indicates that the HIP message received was invalid because
- *       some type, length, or value was out of range or because the
- *       request was rejected for policy reasons.  To avoid a denial of
- *       service attack using forged messages, this status may only be
- *       returned for packets whose HMAC (if present) and SIGNATURE have
- *       been verified.  This status MUST be sent in response to any
- *       error not covered by one of the other status types, and should
- *       not contain details to avoid leaking information to someone
- *       probing a node.  To aid debugging, more detailed error
- *       information SHOULD be written to a console or log.
- * @def  HIP_NTF_NO_DH_PROPOSAL_CHOSEN
- *       None of the proposed group IDs was acceptable.
- * @def  HIP_NTF_INVALID_DH_CHOSEN
- *       The D-H Group ID field does not correspond to one offered
- *       by the Responder.
- * @def  HIP_NTF_NO_HIP_PROPOSAL_CHOSEN
- *       None of the proposed HIP Transform crypto suites was
- *       acceptable.
- * @def  HIP_NTF_INVALID_HIP_TRANSFORM_CHOSEN
- *       The HIP Transform crypto suite does not correspond to
- *       one offered by the Responder.
- * @def  HIP_NTF_AUTHENTICATION_FAILED
- *       Sent in response to a HIP signature failure, except when
- *       the signature verification fails in a NOTIFY message.
- * @def  HIP_NTF_CHECKSUM_FAILED
- *       Sent in response to a HIP checksum failure.
- * @def  HIP_NTF_HMAC_FAILED
- *       Sent in response to a HIP HMAC failure.
- * @def  HIP_NTF_ENCRYPTION_FAILED
- *       The Responder could not successfully decrypt the
- *       ENCRYPTED parameter.
- * @def  HIP_NTF_INVALID_HIT
- *       Sent in response to a failure to validate the peer's
- *       HIT from the corresponding HI.
- * @def  HIP_NTF_BLOCKED_BY_POLICY
- *       The Responder is unwilling to set up an association
- *       for some policy reason (e.g.\ received HIT is NULL
- *       and policy does not allow opportunistic mode).
- * @def  HIP_NTF_SERVER_BUSY_PLEASE_RETRY
- *       The Responder is unwilling to set up an association
- *       as it is suffering under some kind of overload and
- *       has chosen to shed load by rejecting your request.
- *       You may retry if you wish, however you MUST find
- *       another (different) puzzle solution for any such
- *       retries.  Note that you may need to obtain a new
- *       puzzle with a new I1/R1 exchange.
- * @def  HIP_NTF_I2_ACKNOWLEDGEMENT
- *       The Responder has received your I2 but had to queue
- *       the I2 for processing.  The puzzle was correctly solved
- *       and the Responder is willing to set up an association
- *       but has currently a number of I2s in processing queue.
- *       R2 will be sent after the I2 has been processed.
- */
-
-/**
- * @defgroup hip_services Additional HIP services
- *
- * Registration types for registering to a service as specified in
- * draft-ietf-hip-registration-02. These are the registration types used in
- * @c REG_INFO, @c REG_REQUEST, @c REG_RESPONSE and @c REG_FAILED parameters.
- * Numbers 0-200 are reserved by IANA.
- * Numbers 201 - 255 are reserved by IANA for private use.
- */
-
-/**
- * @defgroup hip_proxy HIP proxy types
- */
-
- /**
- * @file
- * @def HIP_SERVICE_RENDEZVOUS
- *      Rendezvous service for relaying I1 packets.
- * @def HIP_SERVICE_RELAY
- *      UDP encapsulated relay service for HIP packets.
- * @def HIP_TOTAL_EXISTING_SERVICES
- *      Total number of services, which must equal the sum of all existing
- *      services.
- */
-
-/**
- * @file
- * @struct hip_rvs_hmac
- *         Rendezvous server hmac. A non-critical parameter whose only 
difference with
- *         the @c HMAC parameter defined in [I-D.ietf-hip-base] is its @c type 
code.
- *         This change causes it to be located after the @c FROM parameter (as
- *         opposed to the @c HMAC)
- *
- * @struct hip_from
- *         Parameter containing the original source IP address of a HIP packet.
- * @struct hip_via_rvs
- *         Parameter containing the IP addresses of traversed rendezvous 
servers.
- * @struct hip_relay_from
- *         Parameter containing the original source IP address and port number
- *         of a HIP packet.
- * @struct hip_relay_to
- *         Parameter containing the IP addresses and source ports of traversed
- *         rendezvous servers.
- * @struct hip_eid_endpoint
- *         This structure is used by the native API to carry local and peer
- *         identities from libc (setmyeid and setpeereid calls) to the HIP
- *         socket handler (setsockopt). It is almost the same as endpoint_hip,
- *         but it is length-padded like HIP parameters to make it usable with
- *         the builder interface.
- */
-
-/**
- * @defgroup hip_ha_controls HIP host association controls
- *
- * These are bitmasks used in the @c hip_hadb_state stucture fields
- * @c local_controls and @c peer_controls.
- *
- * @c local_controls defines the flags of the current host, while peer_controls
- * define the flags of the peer. The flags are used to indicate the state or
- * status of the host. A status can be, for example, that we have requested
- * for a service or that we are capable of offering a service.
- *
- * Bitmask for local controls:
- * <pre>
- * 0000 0000 0000 0000
- * |||| |||| |||| |||+- 0x0001 We have requested an unsupported service.
- * |||| |||| |||| ||+-- 0x0002 - free -
- * |||| |||| |||| |+--- 0x0004 - free -
- * |||| |||| |||| +---- 0x0008 - free -
- * |||| |||| |||+------ 0x0010 - free -
- * |||| |||| ||+------- 0x0020 - free -
- * |||| |||| |+-------- 0x0040 - free -
- * |||| |||| +--------- 0x0080 - free -
- * |||| |||+----------- 0x0100 - free -
- * |||| ||+------------ 0x0200 - free -
- * |||| |+------------- 0x0400 - free -
- * |||| +-------------- 0x0800 We have granted the peer full relay service
- * |||+---------------- 0x1000 We have requested full relay service.
- * ||+----------------- 0x2000 Unused
- * |+------------------ 0x4000 We have requested HIP relay service.
- * +------------------- 0x8000 We have requested RVS service.
- * </pre>
- * Bitmask for peer controls:
- * <pre>
- * 0000 0000 0000 0000
- * |||| |||| |||| |||+- 0x0001 Peer granted an unsupported service to us.
- * |||| |||| |||| ||+-- 0x0002 Peer offers an unsupported service.
- * |||| |||| |||| |+--- 0x0004 Peer refused to grant us an unsupported service.
- * |||| |||| |||| +---- 0x0008 - free -
- * |||| |||| |||+------ 0x0010 - free -
- * |||| |||| ||+------- 0x0020 Peer has refused to grant us full relay service
- * |||| |||| |+-------- 0x0040 Peer refused to grant us HIP relay service.
- * |||| |||| +--------- 0x0080 Peer refused to grant us RVS service.
- * |||| |||+----------- 0x0100 - free -
- * |||| ||+------------ 0x0200 - free -
- * |||| |+------------- 0x0400 Peer has granted us full relay service
- * |||| +-------------- 0x0800 Peer granted HIP relay service to us.
- * |||+---------------- 0x1000 Peer granted RVS service to us.
- * ||+----------------- 0x2000 Peer offers full relay service
- * |+------------------ 0x4000 Peer offers HIP relay service.
- * +------------------- 0x8000 Peer offers RVS service.
- * </pre>
- *
- * @note There has been some confusion about which bit does what and which of
- * the control fields to alter. To avoid this confusion, please do not alter
- * the @c local_controls and @c peer_controls fields directly. Instead use
- * functions hip_hadb_set_local_controls(), hip_hadb_set_peer_controls(),
- * hip_hadb_cancel_local_controls(), hip_hadb_cancel_peer_controls().
- * @note Do not confuse these values with HIP packet Controls values.
- *
- * @def HIP_HA_CTRL_NONE
- *      Clears all control values. To clear all local controls call
- *      hip_hadb_set_local_controls() with this mask. To clear all peer 
controls
- *      call hip_hadb_set_peer_controls() with this mask.
-  * @def HIP_HA_CTRL_LOCAL_REQ_UNSUP
- *      The host association has requested unsupported service in an I1 or an
- *      UPDATE packet. This flag is set if the user requests a service that
- *      is unsupported in HIPL. A service request of such kind is possible 
using
- *      <code>hipconf add server</code> with service numbers.
- * @def HIP_HA_CTRL_LOCAL_REQ_RELAY
- *      The host association has requested HIP relay service in an I1 or an
- *      UPDATE packet.
- * @def HIP_HA_CTRL_LOCAL_REQ_RVS
- *      The host association has requested rendezvous service in an I1 or an
- *      UPDATE packet.
- * @def HIP_HA_CTRL_LOCAL_REQ_ANY
- *      An OR mask of every existing local request mask.
- * @def HIP_HA_CTRL_PEER_GRANTED_UNSUP
- *      The peer has granted us unsupported service in a REG_RESPONSE parameter
- *      received in an R2 packet or an UPDATE packet. The peer has granted us
- *      a service that HIPL does not support.
- * @def HIP_HA_CTRL_PEER_GRANTED_RELAY
- *      The peer has granted us relay service in a REG_RESPONSE parameter
- *      received in an R2 packet or an UPDATE packet.
- * @def HIP_HA_CTRL_PEER_GRANTED_RVS
- *      The peer has granted us rendezvous service in a REG_RESPONSE parameter
- *      received in an R2 packet or an UPDATE packet.
- * @def HIP_HA_CTRL_PEER_UNSUP_CAPABLE
- *      The peer has announced in an R1 or UPDATE packet that it offers an
- *      unsupported service.
- * @def HIP_HA_CTRL_PEER_RELAY_CAPABLE
- *      The peer has announced in an R1 or UPDATE packet that it offers HIP
- *      relay service.
- * @def HIP_HA_CTRL_PEER_RVS_CAPABLE
- *      The peer has announced in an R1 or UPDATE packet that it offers
- *      rendezvous service.
- */
-
-/**
- * @defgroup hip_packet_controls HIP packet Controls field values
- *
- * These are the values that are used in the HIP message Controls field. More
- * importantantly, these are <span style="color:#f00;">the only values allowed
- * in that field.</span> Do not put any other bits on wire in the Controls
- * field.
- * @note Do not confuse these values with HIP host association ontrol values.
- */
-
-/**
- * @defgroup hip_ha_state HIP association states
- *
- * HIP states as specifed in section 4.4.1.\ of draft-ietf-hip-base-10.
- *
- * The states are: UNASSOCIATED, I1-SENT, I2-SENT, R2-SENT ESTABLISHED, 
CLOSING,
- * CLOSED, E-FAILED.
- */
-
-/**
- * @file
- * @def HIP_STATE_NONE
- *      No state, structure unused.
- * @def HIP_STATE_UNASSOCIATED
- *      UNASSOCIATED, state machine start.
- * @def HIP_STATE_I1_SENT
- *      I1-SENT, initiating base exchange.
- * @def HIP_STATE_I2_SENT
- *      I2-SENT, waiting to complete base exchange.
- * @def HIP_STATE_R2_SENT
- *      R2-SENT, waiting to complete base exchange.
- * @def HIP_STATE_ESTABLISHED
- *      ESTABLISHED, HIP association established.
- * @def HIP_STATE_CLOSING
- *      CLOSING, HIP association closing, no data can be sent.
- * @def HIP_STATE_CLOSED
- *      CLOSED, HIP association closed, no data can be sent.
- * @def HIP_STATE_FAILED
- *      E-FAILED, HIP exchange failed.
- */
-
 #endif /* DOXYGEN_H */

=== modified file 'hipd/accessor.h'
--- hipd/accessor.h     2010-03-19 08:47:02 +0000
+++ hipd/accessor.h     2010-04-14 18:51:38 +0000
@@ -14,10 +14,9 @@
 #include "config.h"
 #include "lib/core/hashtable.h"
 
-/** @addtogroup daemon_states
+/** @defgroup daemon_states HIP daemon states
  * @{
  */
-
 /** Low mask for daemon states. */
 #define HIPD_STATE_MASK         0xff
 /** Daemon is ok and executing. */
@@ -29,9 +28,7 @@
 
 /** Daemon is restarting. */
 #define HIPD_FLAG_RESTART       0x00000100
-
-
-/* @}  */
+/* @} */
 
 #define INDEX_HASH_LENGTH       SHA_DIGEST_LENGTH
 

=== modified file 'hipd/input.c'
--- hipd/input.c        2010-04-13 15:52:03 +0000
+++ hipd/input.c        2010-04-14 18:51:38 +0000
@@ -2997,10 +2997,19 @@
 }
 
 /**
- * @addtogroup receive_functions
+ * Functions for receiving HIP control packets.
+ *
+ * These functions are called after a HIP control packet is received by
+ * hip_receive_control_packet()-function and the packet is detected to be a HIP
+ * control packet. The purpose of these functions is to decide whether to
+ * handle the packet at all. This decision is based first and foremost on the
+ * state of the current host association. If the packet is to be handled, all
+ * handling should be done in respective handle-function.
+ *
+ * @defgroup receive_functions HIP receive functions
+ * @see      handle_functions
  * @{
- */
-/**
+ *
  * Determines the action to be executed for an incoming I1 packet.
  *
  * This function is called when a HIP control packet is received by

=== modified file 'lib/conf/hipconf.h'
--- lib/conf/hipconf.h  2010-03-14 14:54:30 +0000
+++ lib/conf/hipconf.h  2010-04-14 18:51:38 +0000
@@ -25,11 +25,8 @@
  * These values are used for TYPE_xxx macros.
  */
 
-/**
- * @addtogroup exec_app_types
+/** @defgroup exec_app_types Execute application types
  * @{
- */
-/**
  * Execute application with opportunistic library preloaded.
  * @see handle_exec_application()
  */
@@ -53,7 +50,7 @@
  * @see handle_exec_application()
  */
 #define LIB_LENGTH      200
-/** @} addtogroup exec_app_types */
+/* @} */
 
 /* for handle_hi() only */
 #define OPT_HI_TYPE 0

=== modified file 'lib/core/builder.c'
--- lib/core/builder.c  2010-04-13 18:08:56 +0000
+++ lib/core/builder.c  2010-04-14 18:51:38 +0000
@@ -3354,8 +3354,7 @@
 
 /**
  * hip_build_param_esp_info - build esp_info parameter
- * \addtogroup params
- * @{ \todo Properly comment parameters of hip_build_param_esp_info() @}
+ * \todo Properly comment parameters of hip_build_param_esp_info()
  *
  * @param msg the message where the parameter will be appended
  * @param keymat_index no desription
@@ -3586,7 +3585,6 @@
 #if 0
 /**
  * build and append host id parameter into a message
- * \addtogroup params
  *
  * @param msg the message where the host id should be appended
  * @param host_id_hdr a hip_host_id structure (public key)

=== modified file 'lib/core/debug.h'
--- lib/core/debug.h    2010-04-13 15:59:48 +0000
+++ lib/core/debug.h    2010-04-14 18:51:38 +0000
@@ -32,7 +32,191 @@
 #define SYSLOG_FACILITY   LOG_LOCAL6
 
 /**
- * @addtogroup ife
+ * Error handling macros used for checking errors. To use these macros, define 
a
+ * label named @c out_err at the end of the function. For example, memory
+ * allocation/deallocation procedure is as follows:
+ * <pre>
+ * int f(void)
+ * {
+ *     char *mem = NULL;
+ *     HIP_IFEL(!(mem = HIP_ALLOC(256, 0)), -1, "alloc\n");
+ *
+ * out_err:
+ *     if (mem != NULL) {
+ *         free(mem);
+ *     }
+ *     return err;
+ * }
+ * </pre>
+ * All functions should return an error value instead of "ok" value. That, is
+ * zero for success and non-zero for failure. Error values are defined in
+ * /usr/include/asm-generic/errno-base.h and /usr/include/asm-generic/errno.h
+ * as follows:
+ *
+ * <pre>
+ * EPERM            1       Operation not permitted
+ * ENOENT           2       No such file or directory
+ * ESRCH            3       No such process
+ * EINTR            4       Interrupted system call
+ * EIO              5       I/O error
+ * ENXIO            6       No such device or address
+ * E2BIG            7       Argument list too long
+ * ENOEXEC          8       Exec format error
+ * EBADF            9       Bad file number
+ * ECHILD          10       No child processes
+ * EAGAIN          11       Try again
+ * ENOMEM          12       Out of memory
+ * EACCES          13       Permission denied
+ * EFAULT          14       Bad address
+ * ENOTBLK         15       Block device required
+ * EBUSY           16       Device or resource busy
+ * EEXIST          17       File exists
+ * EXDEV           18       Cross-device link
+ * ENODEV          19       No such device
+ * ENOTDIR         20       Not a directory
+ * EISDIR          21       Is a directory
+ * EINVAL          22       Invalid argument
+ * ENFILE          23       File table overflow
+ * EMFILE          24       Too many open files
+ * ENOTTY          25       Not a typewriter
+ * ETXTBSY         26       Text file busy
+ * EFBIG           27       File too large
+ * ENOSPC          28       No space left on device
+ * ESPIPE          29       Illegal seek
+ * EROFS           30       Read-only file system
+ * EMLINK          31       Too many links
+ * EPIPE           32       Broken pipe
+ * EDOM            33       Math argument out of domain of func
+ * ERANGE          34       Math result not representable
+ * EDEADLK         35       Resource deadlock would occur
+ * ENAMETOOLONG    36       File name too long
+ * ENOLCK          37       No record locks available
+ * ENOSYS          38       Function not implemented
+ * ENOTEMPTY       39       Directory not empty
+ * ELOOP           40       Too many symbolic links encountered
+ * EWOULDBLOCK     EAGAIN   Operation would block
+ * ENOMSG          42       No message of desired type
+ * EIDRM           43       Identifier removed
+ * ECHRNG          44       Channel number out of range
+ * EL2NSYNC        45       Level 2 not synchronized
+ * EL3HLT          46       Level 3 halted
+ * EL3RST          47       Level 3 reset
+ * ELNRNG          48       Link number out of range
+ * EUNATCH         49       Protocol driver not attached
+ * ENOCSI          50       No CSI structure available
+ * EL2HLT          51       Level 2 halted
+ * EBADE           52       Invalid exchange
+ * EBADR           53       Invalid request descriptor
+ * EXFULL          54       Exchange full
+ * ENOANO          55       No anode
+ * EBADRQC         56       Invalid request code
+ * EBADSLT         57       Invalid slot
+ * EDEADLOCK       EDEADLK
+ * EBFONT          59       Bad font file format
+ * ENOSTR          60       Device not a stream
+ * ENODATA         61       No data available
+ * ETIME           62       Timer expired
+ * ENOSR           63       Out of streams resources
+ * ENONET          64       Machine is not on the network
+ * ENOPKG          65       Package not installed
+ * EREMOTE         66       Object is remote
+ * ENOLINK         67       Link has been severed
+ * EADV            68       Advertise error
+ * ESRMNT          69       Srmount error
+ * ECOMM           70       Communication error on send
+ * EPROTO          71       Protocol error
+ * EMULTIHOP       72       Multihop attempted
+ * EDOTDOT         73       RFS specific error
+ * EBADMSG         74       Not a data message
+ * EOVERFLOW       75       Value too large for defined data type
+ * ENOTUNIQ        76       Name not unique on network
+ * EBADFD          77       File descriptor in bad state
+ * EREMCHG         78       Remote address changed
+ * ELIBACC         79       Can not access a needed shared library
+ * ELIBBAD         80       Accessing a corrupted shared library
+ * ELIBSCN         81       .lib section in a.out corrupted
+ * ELIBMAX         82       Attempting to link in too many shared libraries
+ * ELIBEXEC        83       Cannot exec a shared library directly
+ * EILSEQ          84       Illegal byte sequence
+ * ERESTART        85       Interrupted system call should be restarted
+ * ESTRPIPE        86       Streams pipe error
+ * EUSERS          87       Too many users
+ * ENOTSOCK        88       Socket operation on non-socket
+ * EDESTADDRREQ    89       Destination address required
+ * EMSGSIZE        90       Message too long
+ * EPROTOTYPE      91       Protocol wrong type for socket
+ * ENOPROTOOPT     92       Protocol not available
+ * EPROTONOSUPPORT 93       Protocol not supported
+ * ESOCKTNOSUPPORT 94       Socket type not supported
+ * EOPNOTSUPP      95       Operation not supported on transport endpoint
+ * EPFNOSUPPORT    96       Protocol family not supported
+ * EAFNOSUPPORT    97       Address family not supported by protocol
+ * EADDRINUSE      98       Address already in use
+ * EADDRNOTAVAIL   99       Cannot assign requested address
+ * ENETDOWN        100      Network is down
+ * ENETUNREACH     101      Network is unreachable
+ * ENETRESET       102      Network dropped connection because of reset
+ * ECONNABORTED    103      Software caused connection abort
+ * ECONNRESET      104      Connection reset by peer
+ * ENOBUFS         105      No buffer space available
+ * EISCONN         106      Transport endpoint is already connected
+ * ENOTCONN        107      Transport endpoint is not connected
+ * ESHUTDOWN       108      Cannot send after transport endpoint shutdown
+ * ETOOMANYREFS    109      Too many references: cannot splice
+ * ETIMEDOUT       110      Connection timed out
+ * ECONNREFUSED    111      Connection refused
+ * EHOSTDOWN       112      Host is down
+ * EHOSTUNREACH    113      No route to host
+ * EALREADY        114      Operation already in progress
+ * EINPROGRESS     115      Operation now in progress
+ * ESTALE          116      Stale NFS file handle
+ * EUCLEAN         117      Structure needs cleaning
+ * ENOTNAM         118      Not a XENIX named type file
+ * ENAVAIL         119      No XENIX semaphores available
+ * EISNAM          120      Is a named type file
+ * EREMOTEIO       121      Remote I/O error
+ * EDQUOT          122      Quota exceeded
+ * ENOMEDIUM       123      No medium found
+ * EMEDIUMTYPE     124      Wrong medium type
+ * ECANCELED       125      Operation Canceled
+ * ENOKEY          126      Required key not available
+ * EKEYEXPIRED     127      Key has expired
+ * EKEYREVOKED     128      Key has been revoked
+ * EKEYREJECTED    129      Key was rejected by service
+ * EOWNERDEAD      130      Owner died
+ * ENOTRECOVERABLE 131      State not recoverable
+ * </pre>
+ * Following error values are defined in /usr/include/netdb.h:
+ * <pre>
+ * NETDB_INTERNAL  -1       See errno.
+ * NETDB_SUCCESS   0        No problem.
+ * HOST_NOT_FOUND  1        Authoritative Answer Host not found.
+ * TRY_AGAIN       2        Non-Authoritative Host not found, or SERVERFAIL.
+ * NO_RECOVERY     3        Non recoverable errors, FORMERR, REFUSED,NOTIMP.
+ * NO_DATA         4        Valid name, no data record of requested type.
+ * NO_ADDRESS      NO_DATA  No address, look for MX record.
+ * EKEYREJECTED    129      Key was rejected by service
+ * EOWNERDEAD      130      Owner died
+ * ENOTRECOVERABLE 131      State not recoverable
+ * </pre>
+ * Following error values for `getaddrinfo' function are defined in
+ * /usr/include/netdb.h:
+ * <pre>
+ * EAI_BADFLAGS    -1       Invalid value for `ai_flags' field.
+ * EAI_NONAME      -2       NAME or SERVICE is unknown.
+ * EAI_AGAIN       -3       Temporary failure in name resolution.
+ * EAI_FAIL        -4       Non-recoverable failure in name res.
+ * EAI_NODATA      -5       No address associated with NAME.
+ * EAI_FAMILY      -6       `ai_family' not supported.
+ * EAI_SOCKTYPE    -7       `ai_socktype' not supported.
+ * EAI_SERVICE     -8       SERVICE not supported for `ai_socktype'.
+ * EAI_ADDRFAMILY  -9       Address family for NAME not supported.
+ * EAI_MEMORY      -10      Memory allocation failure.
+ * EAI_SYSTEM      -11      System error returned in `errno'.
+ * EAI_OVERFLOW    -12      Argument buffer overflow.
+ * </pre>
+ *
+ * @defgroup ife Error handling macros
  * @{
  */
 #define HIP_INFO(...) hip_print_str(DEBUG_LEVEL_INFO, __FILE__, __LINE__, 
__FUNCTION__, __VA_ARGS__)
@@ -42,8 +226,11 @@
 #define HIP_ASSERT(s) { if (!(s)) {HIP_DIE("assertion failed\n"); }}
 /** @} */
 
-/**
- * @addtogroup debug
+/** @defgroup debug HIP debug macros
+ *
+ * Unfortunately Doxygen gets confused when dealing with the extensive '\' and
+ * '#' characters that these macros contain. This documentation is therefore
+ * messed up. You can find the implementation of these macros from 
lib/core/debug.h.
  * @{
  */
 #ifdef CONFIG_HIP_DEBUG
@@ -72,8 +259,7 @@
 #else
 #define HIP_DEMO(...) do {} while (0)
 #endif
-
-/** @} */
+/* @} */
 
 /* Debug groups define groups of debug messages which belong to the
  * same logical part of hip. Debug messages can be enabled or disabled more

=== modified file 'lib/core/icomm.h'
--- lib/core/icomm.h    2010-03-19 08:47:02 +0000
+++ lib/core/icomm.h    2010-04-14 18:51:38 +0000
@@ -29,8 +29,8 @@
 #define HIP_MSG_SOCKET_OPT 2
 #define HIP_MSG_GET_HIT_LIST 3
 
-/** @addtogroup hip_so
- * HIP socket options. Define a constant HIP_MSG_NEWMODE which has value
+/** @defgroup hip_so HIP socket options
+ * Define a constant HIP_MSG_NEWMODE which has value
  * between 0 and HIP_MSG_ROOT_MAX. You may also need to increase the value of
  * HIP_MSG_ROOT_MAX.
  *
@@ -70,12 +70,6 @@
 #define HIP_MSG_MAP_ID_TO_ADDR                   34
 #define HIP_MSG_LSI_TO_HIT                       35
 #define HIP_MSG_ANY_MAX                          63
-
-
-/** @addtogroup hip_so
- * HIP socket options.
- * @{
- */
 #define HIP_MSG_ROOT_MIN                         64
 #define HIP_MSG_ADD_LOCAL_HI                     65
 #define HIP_MSG_DEL_LOCAL_HI                     66
@@ -205,8 +199,8 @@
 #define HIP_MSG_HANDOVER_SOFT                    200
 #define HIP_MSG_FIREWALL_STATUS                  201
 #define HIP_MSG_FW_FLUSH_SYS_OPP_HIP             202
+/* @} */
 
-/** @} */
 /* inclusive */
 #define HIP_MSG_ROOT_MAX                         255
 

=== modified file 'lib/core/protodefs.h'
--- lib/core/protodefs.h        2010-03-19 09:00:54 +0000
+++ lib/core/protodefs.h        2010-04-14 18:51:38 +0000
@@ -29,7 +29,11 @@
 
 #define HIP_MAX_PACKET 4096
 #define HIP_MAX_NETWORK_PACKET 2048
-/** @addtogroup hip_msg
+
+/**
+ * @defgroup hip_msg HIP daemon message types
+ * @note Don't make these values higher than 255.
+ *       The variable, which stores this type, is 8 bits.
  * @{
  */
 #define HIP_I1                  1
@@ -37,15 +41,15 @@
 #define HIP_I2                  3
 #define HIP_R2                  4
 #define HIP_CER                 5
-#define HIP_BOS                 11 /* removed from ietf-hip-base-01 */
+#define HIP_BOS                 11 ///< removed from ietf-hip-base-01
 #define HIP_UPDATE              16
 #define HIP_NOTIFY              17
 #define HIP_CLOSE               18
 #define HIP_CLOSE_ACK           19
 /* 20 was already occupied by HIP_PSIG so shifting HIP_PSIG and HIP_TRIG plus 
1*/
 #define HIP_HDRR                20
-#define HIP_PSIG                21 /* lightweight HIP pre signature */
-#define HIP_TRIG                22 /* lightweight HIP signature trigger*/
+#define HIP_PSIG                21 ///< lightweight HIP pre signature
+#define HIP_TRIG                22 ///< lightweight HIP signature trigger
 #define HIP_LUPDATE             23
 #define HIP_DATA                32
 #define HIP_PAYLOAD             64
@@ -72,21 +76,55 @@
 #define HIP_KHI_CONTEXT_ID_INIT { 0xF0, 0xEF, 0xF0, 0x2F, 0xBF, 0xF4, 0x3D, 
0x0F, \
                                   0xE7, 0x93, 0x0C, 0x3C, 0x6E, 0x61, 0x74, 
0xEA }
 
-/** @addtogroup hip_param_type_numbers
+
+/**
+ * Type values used in Host Identity Protocol (HIP) parameters.
+ *
+ * These are the type values used in Host Identity Protocol (HIP) parameters
+ * defined in [draft-ietf-hip-base] and other drafts expanding it. Because the
+ * ordering (from lowest to highest) of HIP parameters is strictly enforced, 
the
+ * parameter type values for existing parameters have been spaced to allow for
+ * future protocol extensions.
+ *
+ * <b>Type values are grouped as follows:</b>
+ * <ul>
+ * <li>0-1023 are used in HIP handshake and update procedures and are covered
+ * by signatures.</li>
+ * <li>1024-2047 are reserved.</li>
+ * <li>2048-4095 are used for parameters related to HIP transform types.</li>
+ * <li>4096-61439 are reserved. However, a subset (32768 - 49141) of this can 
be
+ * used for HIPL private parameters.</li>
+ * <li>61440-62463 are used for signatures and signed MACs.</li>
+ * <li>62464-63487 are used for parameters that fall outside of the signed area
+ * of the packet.</li>
+ * <li>63488-64511 are used for rendezvous and other relaying services.</li>
+ * <li>64512-65535 are reserved.</li>
+ * </ul>
+ *
+ * @defgroup hip_param_type_numbers HIP parameter type values
+ * @see      hip_tlv
+ * @see      hip_param_func
+ * @see      <a 
href="http://hip4inter.net/documentation/drafts/draft-ietf-hip-base-06-pre180506.txt";>
+ *           draft-ietf-hip-base-06-pre180506</a> section 5.2.
+ * @note     The order of the parameters is strictly enforced. The parameters
+ *           @b must be in order from lowest to highest.
  * @{
  */
+
+/** Defines the minimum parameter type value.
+ * @note exclusive */
 #define HIP_PARAM_MIN                  -1
 
 #define HIP_PARAM_ESP_INFO             65
 #define HIP_PARAM_R1_COUNTER           128
 #define HIP_PARAM_LOCATOR              193
-//NAT branch
-/*195 is temp value, check me later**/
-#define HIP_PARAM_STUN                     195
-//end NAT branch
-#define HIP_PARAM_HASH_CHAIN_VALUE     221
-#define HIP_PARAM_HASH_CHAIN_ANCHORS   222
-#define HIP_PARAM_HASH_CHAIN_PSIG      223
+// NAT branch
+/* 195 is temp value, check me later */
+#define HIP_PARAM_STUN                 195
+// end NAT branch
+#define HIP_PARAM_HASH_CHAIN_VALUE     221 ///< lhip hash chain. 221 is is 
temporary.
+#define HIP_PARAM_HASH_CHAIN_ANCHORS   222 ///< lhip hash chain anchors. 222 
is temporary.
+#define HIP_PARAM_HASH_CHAIN_PSIG      223 ///< lhip hash chain signature. 223 
is temporary.
 #define HIP_PARAM_PUZZLE               257
 #define HIP_PARAM_SOLUTION             321
 #define HIP_PARAM_CHALLENGE_RESPONSE   322
@@ -182,8 +220,8 @@
 #define HIP_PARAM_HIP_SIGNATURE         61697
 #define HIP_PARAM_ECHO_RESPONSE         63425
 #define HIP_PARAM_ECHO_REQUEST          63661
-#define HIP_PARAM_RELAY_FROM            63998
-#define HIP_PARAM_RELAY_TO              64002
+#define HIP_PARAM_RELAY_FROM            63998 ///< HIP relay related parameter 
@note former FROM_NAT
+#define HIP_PARAM_RELAY_TO              64002 ///< HIP relay related parameter 
@note Former VIA_RVS_NAT
 //#define HIP_PARAM_REG_FROM            64010
 #define HIP_PARAM_TO_PEER               64006
 #define HIP_PARAM_FROM_PEER             64008
@@ -192,29 +230,78 @@
 #define HIP_PARAM_FROM                  65498
 #define HIP_PARAM_RVS_HMAC              65500
 #define HIP_PARAM_VIA_RVS               65502
-#define HIP_PARAM_RELAY_HMAC            65520
+#define HIP_PARAM_RELAY_HMAC            65520 ///< HIP relay related parameter
 #define HIP_PARAM_HOSTNAME              65521
 #define HIP_PARAM_HIT_INFO              65524
 
-#define HIP_PARAM_MAX                   65536
+#define HIP_PARAM_MAX                   65536 ///< Defines the maximum 
parameter type value. @note exclusive
 /* @} */
 
-/** @addtogroup notification
+/**
+ * HIP NOTIFICATION parameter values.
+ *
+ * NOTIFICATION parameter error types used in the "Notify Message Type"-field 
of
+ * NOTIFICATION parameter as specified in section 5.2.16. of
+ * draft-ietf-hip-base-06.
+ *
+ * @defgroup notification NOTIFICATION parameter values
+ * @see      hip_notification
  * @{
  */
-#define HIP_NTF_UNSUPPORTED_CRITICAL_PARAMETER_TYPE 1
-#define HIP_NTF_INVALID_SYNTAX                      7
+/** Sent if the parameter type has the "critical" bit set and the
+ *  parameter type is not recognized.  Notification Data contains the
+ *  two octet parameter type. */
+#define HIP_NTF_UNSUPPORTED_CRITICAL_PARAMETER_TYPE  1
+/** Indicates that the HIP message received was invalid because some
+ *  type, length, or value was out of range or because the request was
+ *  rejected for policy reasons.  To avoid a denial of service attack
+ *  using forged messages, this status may only be returned for
+ *  packets whose HMAC (if present) and SIGNATURE have been verified.
+ *  This status MUST be sent in response to any error not covered by
+ *  one of the other status types, and should not contain details to
+ *  avoid leaking information to someone probing a node.  To aid
+ *  debugging, more detailed error information SHOULD be written to a
+ *  console or log. */
+#define HIP_NTF_INVALID_SYNTAX                       7
+/** None of the proposed group IDs was acceptable. */
 #define HIP_NTF_NO_DH_PROPOSAL_CHOSEN               14
+/** The D-H Group ID field does not correspond to one offered
+ *  by the Responder. */
 #define HIP_NTF_INVALID_DH_CHOSEN                   15
+/** None of the proposed HIP Transform crypto suites was acceptable. */
 #define HIP_NTF_NO_HIP_PROPOSAL_CHOSEN              16
+/** The HIP Transform crypto suite does not correspond to one offered
+ *  by the Responder. */
 #define HIP_NTF_INVALID_HIP_TRANSFORM_CHOSEN        17
+/** Sent in response to a HIP signature failure, except when the
+ *  signature verification fails in a NOTIFY message. */
 #define HIP_NTF_AUTHENTICATION_FAILED               24
+/** Sent in response to a HIP checksum failure. */
 #define HIP_NTF_CHECKSUM_FAILED                     26
+/** Sent in response to a HIP HMAC failure. */
 #define HIP_NTF_HMAC_FAILED                         28
+/** The Responder could not successfully decrypt the ENCRYPTED
+ *  parameter. */
 #define HIP_NTF_ENCRYPTION_FAILED                   32
+/** Sent in response to a failure to validate the peer's HIT from the
+ *  corresponding HI. */
 #define HIP_NTF_INVALID_HIT                         40
+/** The Responder is unwilling to set up an association for some
+ *  policy reason (e.g.\ received HIT is NULL and policy does not
+ *  allow opportunistic mode). */
 #define HIP_NTF_BLOCKED_BY_POLICY                   42
+/** The Responder is unwilling to set up an association as it is
+ *  suffering under some kind of overload and has chosen to shed load
+ *  by rejecting your request.  You may retry if you wish, however you
+ *  MUST find another (different) puzzle solution for any such
+ *  retries.  Note that you may need to obtain a new puzzle with a new
+ *  I1/R1 exchange. */
 #define HIP_NTF_SERVER_BUSY_PLEASE_RETRY            44
+/** The Responder has received your I2 but had to queue the I2 for
+ *  processing.  The puzzle was correctly solved and the Responder is
+ *  willing to set up an association but has currently a number of I2s
+ *  in processing queue.  R2 will be sent after the I2 has been
+ *  processed. */
 #define HIP_NTF_I2_ACKNOWLEDGEMENT                  46
 /* @} */
 
@@ -284,66 +371,150 @@
 #define HIP_USER_VER_RES            0x02       /* Internal messages */
 
 /**
- * @addtogroup hip_ha_controls
+ * @defgroup hip_ha_controls HIP host association controls
+ *
+ * These are bitmasks used in the @c hip_hadb_state stucture fields
+ * @c local_controls and @c peer_controls.
+ *
+ * @c local_controls defines the flags of the current host, while peer_controls
+ * define the flags of the peer. The flags are used to indicate the state or
+ * status of the host. A status can be, for example, that we have requested
+ * for a service or that we are capable of offering a service.
+ *
+ * Bitmask for local controls:
+ * <pre>
+ * 0000 0000 0000 0000
+ * |||| |||| |||| |||+- 0x0001 We have requested an unsupported service.
+ * |||| |||| |||| ||+-- 0x0002 - free -
+ * |||| |||| |||| |+--- 0x0004 - free -
+ * |||| |||| |||| +---- 0x0008 - free -
+ * |||| |||| |||+------ 0x0010 - free -
+ * |||| |||| ||+------- 0x0020 - free -
+ * |||| |||| |+-------- 0x0040 - free -
+ * |||| |||| +--------- 0x0080 - free -
+ * |||| |||+----------- 0x0100 - free -
+ * |||| ||+------------ 0x0200 - free -
+ * |||| |+------------- 0x0400 - free -
+ * |||| +-------------- 0x0800 We have granted the peer full relay service
+ * |||+---------------- 0x1000 We have requested full relay service.
+ * ||+----------------- 0x2000 Unused
+ * |+------------------ 0x4000 We have requested HIP relay service.
+ * +------------------- 0x8000 We have requested RVS service.
+ * </pre>
+ * Bitmask for peer controls:
+ * <pre>
+ * 0000 0000 0000 0000
+ * |||| |||| |||| |||+- 0x0001 Peer granted an unsupported service to us.
+ * |||| |||| |||| ||+-- 0x0002 Peer offers an unsupported service.
+ * |||| |||| |||| |+--- 0x0004 Peer refused to grant us an unsupported service.
+ * |||| |||| |||| +---- 0x0008 - free -
+ * |||| |||| |||+------ 0x0010 - free -
+ * |||| |||| ||+------- 0x0020 Peer has refused to grant us full relay service
+ * |||| |||| |+-------- 0x0040 Peer refused to grant us HIP relay service.
+ * |||| |||| +--------- 0x0080 Peer refused to grant us RVS service.
+ * |||| |||+----------- 0x0100 - free -
+ * |||| ||+------------ 0x0200 - free -
+ * |||| |+------------- 0x0400 Peer has granted us full relay service
+ * |||| +-------------- 0x0800 Peer granted HIP relay service to us.
+ * |||+---------------- 0x1000 Peer granted RVS service to us.
+ * ||+----------------- 0x2000 Peer offers full relay service
+ * |+------------------ 0x4000 Peer offers HIP relay service.
+ * +------------------- 0x8000 Peer offers RVS service.
+ * </pre>
+ *
+ * @note There has been some confusion about which bit does what and which of
+ * the control fields to alter. To avoid this confusion, please do not alter
+ * the @c local_controls and @c peer_controls fields directly. Instead use
+ * functions hip_hadb_set_local_controls(), hip_hadb_set_peer_controls(),
+ * hip_hadb_cancel_local_controls(), hip_hadb_cancel_peer_controls().
+ * @note Do not confuse these values with HIP packet Controls values.
  * @{
  */
 /* REMEMBER TO UPDATE BITMAP IN DOC/DOXYGEN.H WHEN YOU ADD/CHANGE THESE! */
-#define HIP_HA_CTRL_NONE                 0x0000
-
-#define HIP_HA_CTRL_LOCAL_REQ_UNSUP      0x0001
-#define HIP_HA_CTRL_LOCAL_REQ_RELAY      0x4000
-#define HIP_HA_CTRL_LOCAL_REQ_RVS        0x8000
-#define HIP_HA_CTRL_LOCAL_REQ_FULLRELAY  0x1000
+#define HIP_HA_CTRL_NONE                    0x0000 ///< Clears all control 
values. To clear all local controls call hip_hadb_set_local_controls() with 
this mask. To clear all peer controls call hip_hadb_set_peer_controls() with 
this mask.
+#define HIP_HA_CTRL_LOCAL_REQ_UNSUP         0x0001 ///< The host association 
has requested unsupported service in an I1 or an UPDATE packet. This flag is 
set if the user requests a service that is unsupported in HIPL. A service 
request of such kind is possible using <code>hipconf add server</code> with 
service numbers.
+#define HIP_HA_CTRL_LOCAL_REQ_RELAY         0x4000 ///< The host association 
has requested HIP relay service in an I1 or an UPDATE packet.
+#define HIP_HA_CTRL_LOCAL_REQ_RVS           0x8000 ///< The host association 
has requested rendezvous service in an I1 or an UPDATE packet.
+#define HIP_HA_CTRL_LOCAL_REQ_FULLRELAY     0x1000
+/** An OR mask of every existing local request mask. */
 /* Keep inside parentheses. */
 #define HIP_HA_CTRL_LOCAL_REQ_ANY        ( \
         HIP_HA_CTRL_LOCAL_REQ_UNSUP | \
         HIP_HA_CTRL_LOCAL_REQ_RELAY | \
-        HIP_HA_CTRL_LOCAL_REQ_RVS | \
+        HIP_HA_CTRL_LOCAL_REQ_RVS   | \
         HIP_HA_CTRL_LOCAL_REQ_FULLRELAY \
         )
 #define HIP_HA_CTRL_LOCAL_GRANTED_FULLRELAY 0x0800
 
-#define HIP_HA_CTRL_PEER_GRANTED_UNSUP   0x0001
-#define HIP_HA_CTRL_PEER_GRANTED_RELAY   0x0800
-#define HIP_HA_CTRL_PEER_GRANTED_RVS     0x1000
-#define HIP_HA_CTRL_PEER_GRANTED_FULLRELAY 0x400
-
-#define HIP_HA_CTRL_PEER_UNSUP_CAPABLE   0x0002
-#define HIP_HA_CTRL_PEER_RELAY_CAPABLE   0x4000
-#define HIP_HA_CTRL_PEER_RVS_CAPABLE     0x8000
-#define HIP_HA_CTRL_PEER_FULLRELAY_CAPABLE 0x2000
-
-#define HIP_HA_CTRL_PEER_REFUSED_UNSUP   0x0004
-#define HIP_HA_CTRL_PEER_REFUSED_RELAY   0x0040
-#define HIP_HA_CTRL_PEER_REFUSED_RVS     0x0080
-#define HIP_HA_CTRL_PEER_REFUSED_FULLRELAY 0x0020
+/** The peer has granted us unsupported service in a REG_RESPONSE parameter
+ *  received in an R2 packet or an UPDATE packet. The peer has granted us a
+ *  service that HIPL does not support. */
+#define HIP_HA_CTRL_PEER_GRANTED_UNSUP      0x0001
+/** The peer has granted us relay service in a REG_RESPONSE parameter
+ *  received in an R2 packet or an UPDATE packet. */
+#define HIP_HA_CTRL_PEER_GRANTED_RELAY      0x0800
+/** The peer has granted us rendezvous service in a REG_RESPONSE parameter
+ *  received in an R2 packet or an UPDATE packet. */
+#define HIP_HA_CTRL_PEER_GRANTED_RVS        0x1000
+/** The peer has announced in an R1 or UPDATE packet that it offers an
+ *  unsupported service. */
+#define HIP_HA_CTRL_PEER_GRANTED_FULLRELAY   0x400
+
+#define HIP_HA_CTRL_PEER_UNSUP_CAPABLE      0x0002
+/** The peer has announced in an R1 or UPDATE packet that it offers HIP
+ *  relay service. */
+#define HIP_HA_CTRL_PEER_RELAY_CAPABLE      0x4000
+/** The peer has announced in an R1 or UPDATE packet that it offers
+ *  rendezvous service. */
+#define HIP_HA_CTRL_PEER_RVS_CAPABLE        0x8000
+#define HIP_HA_CTRL_PEER_FULLRELAY_CAPABLE  0x2000
+
+#define HIP_HA_CTRL_PEER_REFUSED_UNSUP      0x0004
+#define HIP_HA_CTRL_PEER_REFUSED_RELAY      0x0040
+#define HIP_HA_CTRL_PEER_REFUSED_RVS        0x0080
+#define HIP_HA_CTRL_PEER_REFUSED_FULLRELAY  0x0020
 
 /* @} */
 
-/** @addtogroup hip_packet_controls
+/**
+ * @defgroup hip_packet_controls HIP packet Controls field values
+ *
+ * These are the values that are used in the HIP message Controls field. More
+ * importantantly, these are <span style="color:#f00;">the only values allowed
+ * in that field.</span> Do not put any other bits on wire in the Controls
+ * field.
+ * @note Do not confuse these values with HIP host association ontrol values.
  * @{
  */
 #define HIP_PACKET_CTRL_ANON             0x0001 /**< HIP packet Controls value 
*/
 #define HIP_PACKET_CTRL_BLIND            0x0004 /**< HIP packet Controls value 
*/
 /* @} */
 
-/** @addtogroup hip_services
+/**
+ * @defgroup hip_services Additional HIP services
+ *
+ * Registration types for registering to a service as specified in
+ * draft-ietf-hip-registration-02. These are the registration types used in
+ * @c REG_INFO, @c REG_REQUEST, @c REG_RESPONSE and @c REG_FAILED parameters.
+ * Numbers 0-200 are reserved by IANA.
+ * Numbers 201 - 255 are reserved by IANA for private use.
  * @{
  */
-#define HIP_SERVICE_RENDEZVOUS           1
-#define HIP_SERVICE_RELAY                2
+#define HIP_SERVICE_RENDEZVOUS             1 ///< Rendezvous service for 
relaying I1 packets
+#define HIP_SERVICE_RELAY                  2 ///< UDP encapsulated relay 
service for HIP packets
 #define HIP_SERVICE_FULLRELAY            204
+/** Total number of services, which must equal the sum of all existing 
services. */
 /* IMPORTANT! This must be the sum of above services. */
-#define HIP_TOTAL_EXISTING_SERVICES      3
+#define HIP_TOTAL_EXISTING_SERVICES        3
 /* @} */
 
-/** @addtogroup hip_proxy
+/**
+ * @defgroup hip_proxy HIP proxy types
  * @{
  */
 #define HIP_PROXY_PASSTHROUGH           0
 #define HIP_PROXY_TRANSLATE             1
 #define HIP_PROXY_I1_SENT               2
-
 /* @} */
 
 /* Registration failure types as specified in draft-ietf-hip-registration-02.
@@ -629,7 +800,16 @@
     uint32_t       new_spi;
 } __attribute__ ((packed));
 
-/** @addtogroup hip_tlv
+/**
+ * Type-length-value data structures in Host Identity Protocol (HIP).
+ *
+ * @defgroup hip_tlv HIP TLV data structures
+ * @see      hip_param_type_numbers
+ * @see      hip_param_func
+ * @see      <a 
href="http://hip4inter.net/documentation/drafts/draft-ietf-hip-base-06-pre180506.txt";>
+ *           draft-ietf-hip-base-06-pre180506</a> section 5.2.
+ * @note     The order of the parameters is strictly enforced. The parameters
+ *           @b must be in order from lowest to highest.
  * @{
  */
 struct hip_r1_counter {
@@ -810,6 +990,11 @@
 } __attribute__ ((packed));
 
 /** draft-ietf-hip-rvs-05 */
+/** Rendezvous server hmac.
+ *  A non-critical parameter whose only difference with the @c HMAC
+ *  parameter defined in [I-D.ietf-hip-base] is its @c type code.
+ *  This change causes it to be located after the @c FROM parameter (as
+ *  opposed to the @c HMAC) */
 struct hip_rvs_hmac {
     hip_tlv_type_t type;  /**< Type code for the parameter. */
     hip_tlv_len_t  length;  /**< Length of the parameter contents in bytes. */
@@ -819,6 +1004,7 @@
 } __attribute__ ((packed));
 
 /** draft-ietf-hip-rvs-05 */
+/** Parameter containing the original source IP address of a HIP packet. */
 struct hip_from {
     hip_tlv_type_t type;   /**< Type code for the parameter. */
     hip_tlv_len_t  length;  /**< Length of the parameter contents in bytes. */
@@ -826,6 +1012,7 @@
 } __attribute__ ((packed));
 
 /** draft-ietf-hip-rvs-05 */
+/** Parameter containing the IP addresses of traversed rendezvous servers. */
 struct hip_via_rvs {
     hip_tlv_type_t type;   /**< Type code for the parameter. */
     hip_tlv_len_t  length;  /**< Length of the parameter contents in bytes. */
@@ -833,6 +1020,8 @@
 } __attribute__ ((packed));
 
 /** draft-ietf-hip-nat-traversal-02 */
+/** Parameter containing the original source IP address and port number
+ * of a HIP packet. */
 struct hip_relay_from {
     hip_tlv_type_t type;  /**< Type code for the parameter. */
     hip_tlv_len_t  length;  /**< Length of the parameter contents in bytes. */
@@ -843,6 +1032,8 @@
 } __attribute__ ((packed));
 
 /** draft-ietf-hip-nat-traversal-02 */
+/** Parameter containing the IP addresses and source ports of traversed
+ *  rendezvous servers. */
 struct hip_relay_to {
     hip_tlv_type_t  type; /**< Type code for the parameter. */
     hip_tlv_len_t   length; /**< Length of the parameter contents in bytes. */
@@ -870,6 +1061,11 @@
     uint8_t        address_and_port[0]; /**< Rendezvous server addresses and 
ports. */
 } __attribute__ ((packed));
 
+/** This structure is used by the native API to carry local and peer
+ *  identities from libc (setmyeid and setpeereid calls) to the HIP
+ *  socket handler (setsockopt). It is almost the same as endpoint_hip,
+ *  but it is length-padded like HIP parameters to make it usable with
+ *  the builder interface. */
 struct hip_eid_endpoint {
     hip_tlv_type_t      type;
     hip_tlv_len_t       length;

=== modified file 'lib/core/state.h'
--- lib/core/state.h    2010-04-13 10:59:42 +0000
+++ lib/core/state.h    2010-04-14 18:51:38 +0000
@@ -20,20 +20,27 @@
 #define HIP_HI_REUSE_ANY                  16
 /* Other flags: keep them to the power of two! */
 
-/** @addtogroup hip_ha_state
+
+/**
+ * @defgroup hip_ha_state HIP association states
+ *
+ * HIP states as specifed in section 4.4.1.\ of draft-ietf-hip-base-10.
+ *
+ * The states are: UNASSOCIATED, I1-SENT, I2-SENT, R2-SENT ESTABLISHED, 
CLOSING,
+ * CLOSED, E-FAILED.
  * @{
  */
 /* When adding new states update debug.h hip_state_str(). Doxygen comments to
  * these states are available at doc/doxygen.h */
-#define HIP_STATE_NONE                   0
-#define HIP_STATE_UNASSOCIATED           1
-#define HIP_STATE_I1_SENT                2
-#define HIP_STATE_I2_SENT                3
-#define HIP_STATE_R2_SENT                4
-#define HIP_STATE_ESTABLISHED            5
-#define HIP_STATE_FAILED                 7
-#define HIP_STATE_CLOSING                8
-#define HIP_STATE_CLOSED                 9
+#define HIP_STATE_NONE                   0 /**< no state, structure unused */
+#define HIP_STATE_UNASSOCIATED           1 /**< state machine start */
+#define HIP_STATE_I1_SENT                2 /**< initiating base exchange */
+#define HIP_STATE_I2_SENT                3 /**< waiting to complete base 
exchange */
+#define HIP_STATE_R2_SENT                4 /**< waiting to complete base 
exchange */
+#define HIP_STATE_ESTABLISHED            5 /**< HIP association established */
+#define HIP_STATE_FAILED                 7 /**< HIP exchange failed */
+#define HIP_STATE_CLOSING                8 /**< HIP association closing, no 
data can be sent */
+#define HIP_STATE_CLOSED                 9 /**< HIP association closed, no 
data can be sent */
 /* @} */
 
 #define HIP_UPDATE_STATE_REKEYING        1 /**< @todo REMOVE */
@@ -553,7 +560,13 @@
     in_port_t       peer_port;
 };
 
-/** @addtogroup hadb_func
+/**
+ * HIP host assosiation function pointer data structures.
+ *
+ * Data structures containing function pointers pointing to functions used for
+ * sending, receiving and handling data and modifying host assosiation state.
+ *
+ * @defgroup hadb_func HIP host assosiation function sets
  * @{
  */
 struct hip_hadb_rcv_func_set {

=== modified file 'lib/gui/hipgui.h'
--- lib/gui/hipgui.h    2010-04-07 14:36:47 +0000
+++ lib/gui/hipgui.h    2010-04-14 18:51:38 +0000
@@ -9,8 +9,7 @@
 
 #include "agent/hitdb.h"
 
-/*!
- * \addtogroup libhipgui
+/** @defgroup libhipgui HIP GUI library
  * @{
  */
 
@@ -34,8 +33,7 @@
 void gui_hiu_clear(void);
 void gui_hiu_add(HIT_Remote *);
 void gui_hiu_count(int);
-
-/*! @} addtogroup libhipgui */
+/* @} */
 
 
 #endif /* HIP_LIB_GUI_HIPGUI_H */

Other related posts:

  • » [hipl-commit] [trunk] Rev 4284: Move most of the contents of doc/doxygen.h into source files. - Diego Biurrun