Changeset 717:571b3abaa5df in freeDiameter for include/freeDiameter/libfdproto.h
- Timestamp:
- Feb 18, 2011, 2:50:37 PM (13 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
include/freeDiameter/libfdproto.h
r706 r717 607 607 int fd_os_is_valid_DiameterIdentity(uint8_t * os, size_t ossz); 608 608 609 /* This checks a string is a valid DiameterIdentity and applies IDNA transformations otherwise (xn--...) */ 610 int fd_os_validate_DiameterIdentity(char ** id, size_t * outsz, int memory /* 0: *id can be realloc'd. 1: *id must be malloc'd on output (was static) */ ); 609 /* The following function validates a string as a Diameter Identity or applies the IDNA transformation on it 610 if *inoutsz is != 0 on entry, *id may not be \0-terminated. 611 memory has the following meaning: 0: *id can be realloc'd. 1: *id must be malloc'd on output (was static) 612 */ 613 int fd_os_validate_DiameterIdentity(char ** id, size_t * inoutsz, int memory); 611 614 612 615 /* Create an order relationship for binary strings (not needed to be \0 terminated). … … 627 630 #define fd_os_almostcasecmp(_o1, _l1, _o2, _l2) fd_os_almostcasecmp_int((os0_t)(_o1), _l1, (os0_t)(_o2), _l2) 628 631 632 /* Analyze a DiameterURI and return its components. 633 Return EINVAL if the URI is not valid. 634 *diamid is malloc'd on function return and must be freed (it is processed by fd_os_validate_DiameterIdentity). 635 *secure is 0 (no security) or 1 (security enabled) on return. 636 *port is 0 (default) or a value in host byte order on return. 637 *transport is 0 (default) or IPPROTO_* on return. 638 *proto is 0 (default) or 'd' (diameter), 'r' (radius), or 't' (tacacs+) on return. 639 */ 640 int fd_os_parse_DiameterURI(uint8_t * uri, size_t urisz, DiamId_t * diamid, size_t * diamidlen, int * secure, uint16_t * port, int * transport, char *proto); 629 641 630 642 /*============================================================*/
Note: See TracChangeset
for help on using the changeset viewer.