Mercurial > hg > freeDiameter
view include/freeDiameter/CMakeLists.txt @ 1510:a2fb51309cd2
Add 3GPP TS 29.345 V15.1.0 (2019-09)
Add AVPs:
- App-Layer-User-Id, UTF8String, code 3801, section 6.3.2
- Assistance-info, Grouped, code 3802, section 6.3.3
- Assistance-Info-Validity-Timer, Unsigned32, code 3803, section 6.3.4
- Discovery-Type, Unsigned32, code 3804, section 6.3.5
- Filter-Id, OctetString, code 3805, section 6.3.9
- MAC-Address, UTF8String, code 3806, section 6.3.11
- Match-Report, Grouped, code 3807, section 6.3.12
- Operating-Channel, Unsigned32, code 3808, section 6.3.14
- P2P-Features, Unsigned32, code 3809, section 6.3.15
- ProSe-App-Code, OctetString, code 3810, section 6.3.16
- ProSe-App-Id, UTF8String, code 3811, section 6.3.17
- ProSe-App-Mask, OctetString, code 3812, section 6.3.18
- ProSe-Discovery-Filter, Grouped, code 3813, section 6.3.20
- PRR-Flags, Unsigned32, code 3814, section 6.3.21
- ProSe-Validity-Timer, Unsigned32, code 3815, section 6.3.22
- Requesting-EPUID, UTF8String, code 3816, section 6.3.23
- Targeted-EPUID, UTF8String, code 3817, section 6.3.26
- Time-Window, Unsigned32, code 3818, section 6.3.27
- WiFi-P2P-Assistance-Info, Grouped, code 3819, section 6.3.30
- WLAN-Assistance-Info, Grouped, code 3820, section 6.3.31
- WLAN-Link-Layer-Id, OctetString, code 3821, section 6.3.32
- WLAN-Link-Layer-Id-List, Grouped, code 3822, section 6.3.33
- Location-Update-Trigger, Grouped, code 3823, section 6.3.42
- Location-Update-Event-Type, Unsigned32, code 3824, section 6.3.43
- Change-Of-Area-Type, Grouped, code 3825, section 6.3.44
- Location-Update-Event-Trigger, Unsigned32, code 3826, section 6.3.45
- Report-Cardinality, Enumerated, code 3827, section 6.3.46
- Minimum-Interval-Time, Unsigned32, code 3828, section 6.3.47
- Periodic-Location-Type, Grouped, code 3829, section 6.3.48
- Location-Report-Interval-Time, Unsigned32, code 3830, section 6.3.49
- Total-Number-Of-Reports, Unsigned32, code 3831, section 6.3.50
- Validity-Time-Announce, Unsigned32, code 3832, section 6.3.36
- Validity-Time-Monitor, Unsigned32, code 3833, section 6.3.37
- Validity-Time-Communication, Unsigned32, code 3834, section 6.3.38
- ProSe-App-Code-Info, Grouped, code 3835, section 6.3.39
- MIC, OctetString, code 3836, section 6.3.40
- UTC-based-Counter, Unsigned32, code 3837, section 6.3.41
- ProSe-Match-Refresh-Timer, Unsigned32, code 3838, section 6.3.52
- ProSe-Metadata-Index-Mask, OctetString, code 3839, section 6.3.60
- App-Identifier, Grouped, code 3840, section 6.3.61
- OS-ID, OctetString, code 3841, section 6.3.62
- OS-App-ID, UTF8String, code 3842, section 6.3.63
- Requesting-RPAUID, UTF8String, code 3843, section 6.3.64
- Target-RPAUID, UTF8String, code 3844, section 6.3.65
- Target-PDUID, OctetString, code 3845, section 6.3.66
- ProSe-Restricted-Code, OctetString, code 3846, section 6.3.67
- ProSe-Restricted-Code-Suffix-Range, OctetString, code 3847, section 6.3.68
- Beginning-Suffix, OctetString, code 3848, section 6.3.69
- Ending-Suffix, OctetString, code 3849, section 6.3.70
- Discovery-Entry-ID, Unsigned32, code 3850, section 6.3.59
- Match-Timestamp, Time, code 3851, section 6.3.71
- PMR-Flags, Unsigned32, code 3852, section 6.3.57
- ProSe-Application-Metadata, UTF8String, code 3853, section 6.3.58
- Discovery-Auth-Request, Grouped, code 3854, section 6.3.53
- Discovery-Auth-Response, Grouped, code 3855, section 6.3.54
- Match-Request, Grouped, code 3856, section 6.3.55
- Match-Report-Info, Grouped, code 3857, section 6.3.56
- Banned-RPAUID, UTF8String, code 3858, section 6.3.73
- Banned-PDUID, OctetString, code 3859, section 6.3.74
- Code-Receiving-Security-Material, Grouped, code 3860, section 6.3.75
- Code-Sending-Security-Material, Grouped, code 3861, section 6.3.76
- DUSK, OctetString, code 3862, section 6.3.77
- DUIK, OctetString, code 3863, section 6.3.78
- DUCK, OctetString, code 3864, section 6.3.79
- MIC-Check-indicator, Unsigned32, code 3865, section 6.3.80
- Encrypted-Bitmask, OctetString, code 3866, section 6.3.81
- ProSe-App-Code-Suffix-Range, OctetString, code 3867, section 6.3.82
- PC5-tech, OctetString, code 3868, section 6.3.84
Note: Name conflict with 3GPP TS 29.154 Time-Window (4204).
Time-Window (3818) in 3GPP TS 29.345 V12.1.0 (2014-12) predates
Time-Window (4204) in 3GPP TS 29.154 V13.1.0 (2016-03).
author | Luke Mewburn <luke@mewburn.net> |
---|---|
date | Sun, 05 Apr 2020 08:27:37 +1000 |
parents | deaa89f4a994 |
children | 699c3fb0c57b |
line wrap: on
line source
#CMake configuration for freeDiameter include directory Project("freeDiameter includes directory" C) ######################## # Configurable parameters # Disable SCTP support completely ? OPTION(DISABLE_SCTP "Disable SCTP support?" OFF) IF (NOT DISABLE_SCTP) OPTION(DEBUG_SCTP "Verbose SCTP (for debug)?" OFF) OPTION(SCTP_USE_MAPPED_ADDRESSES "Use v6-mapped v4 addresses in SCTP (workaround some SCTP limitations)?" OFF) ENDIF (NOT DISABLE_SCTP) # Find TODO items in the code easily ? OPTION(ERRORS_ON_TODO "(development) Generate compilation errors on TODO items ?" OFF) # Compiler warnings are fatal? OPTION(ERRORS_ON_WARNINGS "(development) Compiler warnings cause compilation errors ?" OFF) # In DEBUG mode, each log can contain pid, calling function and file for easy debug. Set to ON to display this information. OPTION(DEBUG_WITH_META "Show calling location in logs?" OFF) # Create the absolute path for searching extensions SET(DEFAULT_EXTENSIONS_PATH ${CMAKE_INSTALL_PREFIX}/${INSTALL_EXTENSIONS_SUFFIX}) # IDNA considerations OPTION(DIAMID_IDNA_IGNORE "Ignore completely invalid characters in Diameter Identities (process blindly)?" OFF) IF (NOT DIAMID_IDNA_IGNORE) OPTION (DIAMID_IDNA_REJECT "Reject internationalized Diameter Identities, do not attempt to convert it (stringprep) ?" OFF) ENDIF (NOT DIAMID_IDNA_IGNORE) # Disable expiration of connections with dynamically connected peers as per RFC 3539 ? (default is enabled) # Note: if someone needs, we could also make the delay configurable here... OPTION(DISABLE_PEER_EXPIRY "Disable RFC3539 Peers Connections Expiration after inactivity?" OFF) # The following workaround increases compatibility with some implementations without breaking anything in freeDiameter, # so it can be enabled without risk. We keep it disabled by default anyway for those people who use freeDiameter to check the # compliancy of their implementation with the Diameter RFC... OPTION(WORKAROUND_ACCEPT_INVALID_VSAI "Do not reject a CER/CEA with a Vendor-Specific-Application-Id AVP containing both Auth- and Acct- application AVPs?" OFF) MARK_AS_ADVANCED(DISABLE_SCTP DEBUG_SCTP SCTP_USE_MAPPED_ADDRESSES ERRORS_ON_TODO DEBUG_WITH_META DIAMID_IDNA_IGNORE DIAMID_IDNA_REJECT DISABLE_PEER_EXPIRY WORKAROUND_ACCEPT_INVALID_VSAI) ######################## ### System checks part INCLUDE (CheckLibraryExists) INCLUDE (CheckFunctionExists) INCLUDE (CheckIncludeFiles) INCLUDE (CheckSymbolExists) INCLUDE (CheckCSourceCompiles) INCLUDE (TestBigEndian) ### System checks -- mandatory support # We need the getopt_long function CHECK_FUNCTION_EXISTS (getopt_long HAVE_LONG_OPTIONS) IF (NOT HAVE_LONG_OPTIONS) MESSAGE(SEND_ERROR "The getopt_long function is not found, please add needed library in build system") ENDIF (NOT HAVE_LONG_OPTIONS) # getifaddrs ? CHECK_FUNCTION_EXISTS (getifaddrs HAVE_GETIFADDRS) IF (NOT HAVE_GETIFADDRS) MESSAGE(SEND_ERROR "The getifaddrs function is currently required by freeDiameter.") ENDIF (NOT HAVE_GETIFADDRS) ### System checks -- for freeDiameter-host.h # Check byte ordering TEST_BIG_ENDIAN(HOST_BIG_ENDIAN) # Check if ntohll is provided on the system CHECK_SYMBOL_EXISTS(ntohll netinet/in.h HAVE_NTOHLL) # malloc.h ? CHECK_INCLUDE_FILES (malloc.h HAVE_MALLOC_H) # strndup ? Missing on OS X CHECK_FUNCTION_EXISTS (strndup HAVE_STRNDUP) ### System checks -- for includes / link # pthreads INCLUDE(FindThreads) SET(CMAKE_THREAD_LIBS_INIT ${CMAKE_THREAD_LIBS_INIT} PARENT_SCOPE) # clock_gettime SET(HAVE_CLOCK_GETTIME "") CHECK_FUNCTION_EXISTS (clock_gettime HAVE_NATIVE_CLOCK_GETTIME) IF (HAVE_NATIVE_CLOCK_GETTIME) SET(CLOCK_GETTIME_LIBS "") SET(HAVE_CLOCK_GETTIME 1) ELSE (HAVE_NATIVE_CLOCK_GETTIME) CHECK_LIBRARY_EXISTS (rt clock_gettime "" HAVE_LIBRT) IF (HAVE_LIBRT) SET(CLOCK_GETTIME_LIBS "-lrt") SET(HAVE_CLOCK_GETTIME 1) ELSE (HAVE_LIBRT) CHECK_LIBRARY_EXISTS (posix4 clock_gettime "" HAVE_LIBPOSIX4) IF (HAVE_LIBPOSIX4) SET(CLOCK_GETTIME_LIBS "-lposix4") SET(HAVE_CLOCK_GETTIME 1) ENDIF (HAVE_LIBPOSIX4) ENDIF (HAVE_LIBRT) ENDIF (HAVE_NATIVE_CLOCK_GETTIME) SET(CLOCK_GETTIME_LIBS ${CLOCK_GETTIME_LIBS} PARENT_SCOPE) # dlopen and dlclose: CMAKE_DL_LIBS # We need the sctp_connectx function among others # We need the IPPROTO_SCTP symbol from sys/socket.h, netinet/in.h or netinet/sctp.h IF(NOT DISABLE_SCTP) CHECK_FUNCTION_EXISTS(sctp_connectx HAVE_NATIVE_SCTP) IF(NOT HAVE_NATIVE_SCTP) FIND_PACKAGE(SCTP REQUIRED) ENDIF(NOT HAVE_NATIVE_SCTP) # Now check the number of args of this function, since it changed between Ubuntu 9.04 and 9.10 SET(CHECK_SCTP_CONNECTX_4_ARGS_SOURCE_CODE " #include <unistd.h> #include <netinet/sctp.h> int main() { return sctp_connectx(0, NULL, 0, NULL); } ") SET(CMAKE_REQUIRED_INCLUDES ${SCTP_INCLUDE_DIR}) SET(CMAKE_REQUIRED_LIBRARIES ${SCTP_LIBRARIES}) CHECK_C_SOURCE_COMPILES("${CHECK_SCTP_CONNECTX_4_ARGS_SOURCE_CODE}" SCTP_CONNECTX_4_ARGS) ELSE (NOT DISABLE_SCTP) MESSAGE(STATUS "Disabled SCTP support.") ENDIF(NOT DISABLE_SCTP) SET(SCTP_INCLUDE_DIR ${SCTP_INCLUDE_DIR} PARENT_SCOPE) SET(SCTP_LIBRARIES ${SCTP_LIBRARIES} PARENT_SCOPE) # IDNA process: we use libidn from GNU (unless the function & header files are included in libc) IF(NOT DIAMID_IDNA_IGNORE AND NOT DIAMID_IDNA_REJECT) FIND_PACKAGE(IDNA) SET(CHECK_IDNA_SOURCE_CODE " #include <idna.h> int main() { return idna_to_ascii_8z(NULL, NULL, 0); } ") SET(CMAKE_REQUIRED_INCLUDES ${IDNA_INCLUDE_DIR}) SET(CMAKE_REQUIRED_LIBRARIES ${IDNA_LIBRARIES}) CHECK_C_SOURCE_COMPILES("${CHECK_IDNA_SOURCE_CODE}" HAS_IDNA_SUPPORT) IF(NOT HAS_IDNA_SUPPORT) MESSAGE(SEND_ERROR "Unable to find idna.h header or idna_to_ascii_8z function, please install libidn-dev or equivalent, or set DIAMID_IDNA_IGNORE or DIAMID_IDNA_REJECT") ENDIF(NOT HAS_IDNA_SUPPORT) ELSE (NOT DIAMID_IDNA_IGNORE AND NOT DIAMID_IDNA_REJECT) MESSAGE(STATUS "Non-default Internationalized Domain Names (IDN) behavior selected (no stringprep).") ENDIF(NOT DIAMID_IDNA_IGNORE AND NOT DIAMID_IDNA_REJECT) SET(IDNA_INCLUDE_DIR ${IDNA_INCLUDE_DIR} PARENT_SCOPE) SET(IDNA_LIBRARIES ${IDNA_LIBRARIES} PARENT_SCOPE) # Require GNU TLS for building the library FIND_PACKAGE(GnuTLS REQUIRED) SET(GNUTLS_INCLUDE_DIR ${GNUTLS_INCLUDE_DIR} PARENT_SCOPE) SET(GNUTLS_LIBRARIES ${GNUTLS_LIBRARIES} PARENT_SCOPE) FIND_PATH(GCRYPT_INCLUDE_DIR NAMES gcrypt.h) IF(NOT GCRYPT_INCLUDE_DIR) MESSAGE(SEND_ERROR "Unable to find gcrypt.h, please install libgcrypt-dev or equivalent") ENDIF(NOT GCRYPT_INCLUDE_DIR) MARK_AS_ADVANCED(GCRYPT_INCLUDE_DIR) SET(GCRYPT_INCLUDE_DIR ${GCRYPT_INCLUDE_DIR} PARENT_SCOPE) # Also we need libgcrypt to... display its version :( FIND_LIBRARY(GCRYPT_LIBRARY NAMES gcrypt ) IF(NOT GCRYPT_LIBRARY) MESSAGE(SEND_ERROR "Unable to find libgcrypt, please install libgcrypt or equivalent") ENDIF(NOT GCRYPT_LIBRARY) SET(GCRYPT_LIBRARY ${GCRYPT_LIBRARY} PARENT_SCOPE) # Check if AI_ADDRCONFIG is available on the system CHECK_SYMBOL_EXISTS(AI_ADDRCONFIG "netdb.h" HAVE_AI_ADDRCONFIG) # Check if barriers are available (for test_fifo) SET(CMAKE_REQUIRED_INCLUDES "pthread.h") SET(CMAKE_REQUIRED_LIBRARIES ${CMAKE_THREAD_LIBS_INIT}) CHECK_FUNCTION_EXISTS (pthread_barrier_wait HAVE_PTHREAD_BAR) SET(HAVE_PTHREAD_BAR ${HAVE_PTHREAD_BAR} PARENT_SCOPE) ########################## # Additional hg version when relevant, stored in version.h if (EXISTS "${CMAKE_SOURCE_DIR}/.hg") # Search for hg binary to use FIND_PROGRAM(HGCOMMAND hg) if (HGCOMMAND) # Ok, add the custom target so that hg is executed at every build ADD_CUSTOM_TARGET(version_information COMMAND ${CMAKE_COMMAND} -D HGCOMMAND="${HGCOMMAND}" -D SRC="${CMAKE_CURRENT_SOURCE_DIR}/version.h.in" -D DST="${CMAKE_CURRENT_BINARY_DIR}/version.h" -P "${CMAKE_SOURCE_DIR}/cmake/Modules/GetVersionWithHg.cmake" DEPENDS "${CMAKE_SOURCE_DIR}/.hg/dirstate" WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} COMMENT "Retrieving version of the hg repository" ) else (HGCOMMAND) # Display at least "unknown" rev in this case SET(FD_PROJECT_VERSION_HG "unknown") CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/version.h.in ${CMAKE_CURRENT_BINARY_DIR}/version.h) ADD_CUSTOM_TARGET(version_information DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/version.h) endif(HGCOMMAND) else (EXISTS "${CMAKE_SOURCE_DIR}/.hg") # We use the pure version number without extension CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/version.h.in ${CMAKE_CURRENT_BINARY_DIR}/version.h) ADD_CUSTOM_TARGET(version_information DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/version.h) endif (EXISTS "${CMAKE_SOURCE_DIR}/.hg") ########################## # LFDPROTO_LIBS = libraries required by the libfdproto. SET(LFDPROTO_LIBS ${CLOCK_GETTIME_LIBS} ${CMAKE_THREAD_LIBS_INIT} ${IDNA_LIBRARIES} PARENT_SCOPE) # And includes paths SET(LFDPROTO_INCLUDES ${IDNA_INCLUDE_DIR} PARENT_SCOPE) # Dependencies: the libraries required by any code linking to libfdproto. SET(LFDPROTO_LINK_INTERFACES ${CMAKE_THREAD_LIBS_INIT} PARENT_SCOPE) # LFDCORE_LIBS = libraries required by the libfdcore (in addition to libfdproto and its dependencies) SET(LFDCORE_LIBS ${CLOCK_GETTIME_LIBS} ${CMAKE_DL_LIBS} ${SCTP_LIBRARIES} ${GCRYPT_LIBRARY} ${GNUTLS_LIBRARIES} PARENT_SCOPE) # And includes paths SET(LFDCORE_INCLUDES ${SCTP_INCLUDE_DIR} ${GNUTLS_INCLUDE_DIR} ${GCRYPT_INCLUDE_DIR} PARENT_SCOPE) # And dependencies SET(LFDCORE_LINK_INTERFACES "" PARENT_SCOPE) # We don't force other libraries, the programs will link with what it needs # (such as libgnutls if it uses GNUTLS_DEBUG() macro # or libfdproto if it uses some of its interfaces directly) # See freeDiameterd/CMakeLists.txt for an example. ########################## # Generate the host.h file CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/freeDiameter-host.h.in ${CMAKE_CURRENT_BINARY_DIR}/freeDiameter-host.h) #### ## INSTALL section ## # The headers from this directory are required to develop new extensions for freeDiameter. INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/freeDiameter-host.h libfdproto.h libfdcore.h extension.h DESTINATION ${INSTALL_HEADERS_SUFFIX} COMPONENT freeDiameter-dev)