AnyConnect Secure Mobility Client
3.1.07021
|
00001 /************************************************************************** 00002 * Copyright (c) 2000, Cisco Systems, All Rights Reserved 00003 *************************************************************************** 00004 * 00005 * File: GenDefs.h 00006 * Date: 8/23/00 00007 * 00008 *************************************************************************** 00009 * NOTE* This file is for PORTABILITY related defines ONLY. 00010 *************************************************************************** 00011 * defines base types to be used by all CVC client components 00012 ***************************************************************************/ 00013 #ifndef __GENDEFS_H 00014 #define __GENDEFS_H 00015 00016 #ifndef _WIN32 00017 00018 #ifndef USES_CONVERSION 00019 #define USES_CONVERSION 00020 #endif 00021 00022 #define PRELIM_UNIX_PORT 00023 00024 #ifdef HAVE_CONFIG_H 00025 #include "config.h" 00026 #endif 00027 00028 #ifdef HAVE_STDINT_H 00029 #ifndef CNI_LINUX_INTERFACE 00030 #include <stdint.h> 00031 #endif 00032 #elif HAVE_INTTYPES_H 00033 #include <inttypes.h> 00034 #endif 00035 00036 #ifdef HAVE_SYS_TYPES_H 00037 #ifndef CNI_LINUX_INTERFACE 00038 #include <sys/types.h> 00039 #else 00040 #include <linux/types.h> 00041 #undef _UINTPTR_T_DEFINED 00042 #undef _INTPTR_T_DEFINED 00043 #endif 00044 #endif 00045 00046 #undef FAR 00047 #define FAR 00048 #undef PASCAL 00049 #define PASCAL 00050 00051 #else //_WIN32 00052 00053 #undef HAVE_CONFIG_H 00054 #undef HAVE_STDINT_H 00055 #undef HAVE_SYS_TYPES_H 00056 #define WORDS_BIGENDIAN 0 00057 00058 #endif //_WIN32 00059 00060 00061 #undef TRUE 00062 #define TRUE 1 00063 00064 #undef FALSE 00065 #define FALSE 0 00066 00067 #ifdef DDKBUILD //building with the DDK as the source. 00068 #include <crtdefs.h> 00069 #endif 00070 00071 // it'd be nice if we could switch to the C99 standard types at some point... 00072 #if defined(HAVE_STDINT_H) || defined(HAVE_INTTYPES_H) 00073 typedef uint8_t bool8; 00074 typedef uint16_t bool16; 00075 typedef uint32_t bool32; 00076 00077 typedef int8_t int8; 00078 typedef int16_t int16; 00079 00080 #if (!defined(CNI_LINUX_INTERFACE) || !defined(CONFIG_ISDN_PPP) || !defined(CONFIG_ISDN_PPP_VJ) || !defined(_SLHC_H)) && !defined(PROTYPES_H) 00081 typedef int32_t int32; 00082 #endif 00083 00084 typedef uint8_t uint8; 00085 typedef uint16_t uint16; 00086 00087 #if !defined(CSSMAPI) && !defined(PROTYPES_H) 00088 typedef uint32_t uint32; 00089 #endif 00090 00091 typedef uint64_t uint64; 00092 #else 00093 //original windows definitions (32 bit) 00094 typedef unsigned char bool8; 00095 typedef unsigned short bool16; 00096 typedef unsigned long bool32; 00097 typedef unsigned char bool8_t; 00098 typedef unsigned short bool16_t; 00099 typedef unsigned long bool32_t; 00100 00101 typedef signed char int8; 00102 typedef signed short int16; 00103 typedef signed long int32; 00104 typedef signed char int8_t; 00105 typedef signed short int16_t; 00106 #if defined(_WIN32) && !defined (HS_TYPES_H_) 00107 typedef signed long int32_t; 00108 #endif 00109 00110 typedef unsigned char uint8; 00111 typedef unsigned short uint16; 00112 #ifndef CSSMAPI 00113 typedef unsigned long uint32; 00114 #endif 00115 typedef unsigned char uint8_t; 00116 typedef unsigned short uint16_t; 00117 #ifdef _WIN32 00118 typedef unsigned long uint32_t; 00119 #endif 00120 00121 #ifdef _WIN32 00122 typedef __int64 int64; 00123 typedef unsigned __int64 uint64; 00124 typedef __int64 int64_t; 00125 typedef unsigned __int64 uint64_t; 00126 #else 00127 typedef long long int64; 00128 typedef unsigned long long int uint64; 00129 typedef long long int64_t; 00130 typedef unsigned long long int uint64_t; 00131 #endif 00132 #endif 00133 00134 // integer types for doing pointer arithmetic, they should be the 00135 // same size as a pointer. Part of the C99 standard, but they aren't 00136 // available everywhere yet. 00137 // These defs should work with IA32 (x86), ILP32 (sparcv8) and LP64 (sparcv9). 00138 // These types are protected with the WIN32 macros (_INTPTR_T_DEFINED), since 00139 // some, but not all of the WIN32 SDK's define these types. 00140 #ifdef _WIN32 00141 #ifndef _INTPTR_T_DEFINED 00142 #if defined(_LP64) 00143 #warning 64 bit 00144 typedef int64 intptr_t; 00145 #else 00146 typedef int32 intptr_t; 00147 #endif 00148 #define _INTPTR_T_DEFINED 00149 #endif 00150 00151 #ifndef _UINTPTR_T_DEFINED 00152 #if defined(_LP64) 00153 #warning 64 bit 00154 typedef uint64 uintptr_t; 00155 #else 00156 typedef uint32 uintptr_t; 00157 #endif 00158 #define _UINTPTR_T_DEFINED 00159 #endif 00160 #endif 00161 00162 #ifndef __OBJC__ /* Mac OS X defines this in ObjectiveC land... */ 00163 typedef int BOOL; 00164 #endif 00165 00166 #ifndef _WIN32 00167 typedef int BOOLEAN; 00168 #endif 00169 00170 #ifdef _WIN32 00171 typedef int mode_t; 00172 #endif 00173 00174 typedef unsigned char uchar; 00175 #ifndef HAVE_SYS_TYPES_H 00176 typedef unsigned int uint; 00177 typedef unsigned short ushort; 00178 typedef unsigned long ulong; 00179 #endif 00180 00181 #ifndef PLATFORM_ANDROID 00182 typedef ulong ULONG; 00183 typedef ulong* PULONG; 00184 #endif 00185 00186 typedef uint32 DWORD; 00187 typedef uint32* PDWORD; 00188 typedef long LONG; 00189 typedef long* PLONG; 00190 typedef int INT; 00191 typedef int* PINT; 00192 typedef uint UINT; 00193 typedef uint* PUINT; 00194 typedef uint16 USHORT; 00195 typedef uint16* PUSHORT; 00196 typedef int16 SHORT; 00197 typedef int16* PSHORT; 00198 typedef uint16 WORD; 00199 typedef uint16* PWORD; 00200 typedef char CHAR; 00201 typedef uchar UCHAR; 00202 typedef char* PCHAR; 00203 typedef uint8 BYTE; 00204 typedef uint8* PBYTE; 00205 #define VOID void 00206 typedef void* PVOID; 00207 #ifdef _WIN32 00208 typedef void* HANDLE; 00209 #else 00210 typedef int HANDLE; 00211 typedef int SOCKET; 00212 typedef const char* LPCTSTR; 00213 typedef const char* LPCSTR; 00214 typedef const char* PCTSTR; 00215 typedef char* LPTSTR; 00216 typedef void* LPVOID; 00217 typedef char* LPSTR; 00218 typedef long* LPLONG; 00219 typedef DWORD* LPDWORD; 00220 typedef signed int INT32; 00221 00222 00223 typedef struct __WSABUF 00224 { 00225 unsigned long len; 00226 char *buf; 00227 } WSABUF, *LPWSABUF; 00228 00229 typedef struct OVERLAPPED 00230 { 00231 void *data; 00232 int fd; 00233 } OVERLAPPED,*LPOVERLAPPED; 00234 00235 typedef struct sockaddr_in SOCKADDR_IN; 00236 typedef struct sockaddr_in6 SOCKADDR_IN6; 00237 00238 #endif //!_WIN32 00239 00240 typedef HANDLE* PHANDLE; 00241 typedef uint8 KIRQL; 00242 00243 typedef long STATUSCODE; 00244 00245 /* function parameter context */ 00246 #undef IN 00247 #define IN 00248 00249 #undef OUT 00250 #define OUT 00251 00252 #undef INOUT 00253 #define INOUT 00254 00255 #undef packed 00256 #define packed 00257 00258 #ifndef CLEAR 00259 #define CLEAR(a) memset(&a,0,sizeof(a)) 00260 #endif 00261 00262 #ifndef POINT_BEYOND 00263 #define POINT_BEYOND(a,t) (t) &((&a)[1]) 00264 #endif 00265 00266 #ifndef MAX 00267 #define MAX(a,b) ((a) > (b) ? (a) : (b)) 00268 #endif 00269 #ifndef MIN 00270 #define MIN(a,b) ((a) < (b) ? (a) : (b)) 00271 #endif 00272 00273 #ifndef _WIN32 00274 #define _ftime ftime 00275 #define _timeb timeb 00276 #define __cdecl 00277 #define __stdcall 00278 #define __fastcall 00279 #ifndef WINAPI 00280 #define WINAPI 00281 #endif 00282 #ifndef CALLBACK 00283 #define CALLBACK 00284 #endif 00285 #endif 00286 00287 #ifndef _WIN32 00288 #undef INVALID_SOCKET 00289 #define INVALID_SOCKET -1 00290 #undef INVALID_FD 00291 #define INVALID_FD -1 00292 #undef SOCKET_ERROR 00293 #define SOCKET_ERROR -1 00294 #undef SOCKADDR 00295 #define SOCKADDR sockaddr 00296 #undef SOCKADDR_IN 00297 #define SOCKADDR_IN sockaddr_in 00298 #undef SOCKADDR_IN6 00299 #define SOCKADDR_IN6 sockaddr_in6 00300 00301 #if defined(PLATFORM_DARWIN) || defined(PLATFORM_APPLE_SSLVPN) || defined(APPLE_IOS) 00302 #define s6_words __u6_addr.__u6_addr16 00303 #elif defined(PLATFORM_LINUX) 00304 #define s6_words s6_addr16 00305 #endif 00306 00307 #endif 00308 00309 #ifndef _CRT_SECURE_NO_DEPRECATE 00310 #define _CRT_SECURE_NO_DEPRECATE 00311 #endif 00312 00313 00314 #if !defined(_WIN32) && !defined(_WIN32_WCE) 00315 00316 #ifndef ZeroMemory 00317 #define ZEROMEM(ptr,cnt) \ 00318 if ( NULL != ptr ) { memset(ptr,0,cnt); } 00319 #define ZeroMemory ZEROMEM 00320 #endif /* ZeroMemory */ 00321 00322 #ifndef SecureZeroMemory 00323 #define SECUREZEROMEM(ptr, cnt) \ 00324 do { \ 00325 size_t size = (size_t)cnt; \ 00326 volatile char *vptr = (volatile char *)ptr; \ 00327 while (size) { \ 00328 *vptr = 0; \ 00329 vptr++; \ 00330 size--; \ 00331 } \ 00332 } while(0); 00333 #define SecureZeroMemory SECUREZEROMEM 00334 #endif /* SecureZeroMemory */ 00335 #endif /* Windows */ 00336 00337 00338 00339 #ifndef _WIN32 00340 #define _strnicmp strncasecmp 00341 #define _stricmp strcasecmp 00342 #endif 00343 00344 #ifndef ARRAY_SIZE 00345 #define ARRAY_SIZE(a) (sizeof(a)/sizeof(a[0])) 00346 #endif 00347 00348 #if !defined(TO_STR) && !defined(TO_TSTR) && !defined(SYMBOL_TO_STR) && !defined(SYMBOL_TO_TSTR) 00349 00350 // use TO_STR(x)/TO_TSTR(x) to stringize (put double quotes around) x 00351 // example: 00352 // std::string foo = TO_STR(15); 00353 // tstring bar = TO_TSTR(15); 00354 // becomes 00355 // std::string foo = "15"; 00356 // tstring bar = _T("15"); 00357 #define TO_STR(x) #x 00358 #define TO_TSTR(x) _T(#x) 00359 00360 // use SYMBOL_TO_STR(x)/SYMBOL_TO_TSTR(x) to stringize 00361 // the definition of symbol x 00362 // example: 00363 // #define MAX_LEN 15 00364 // std::string foo = SYMBOL_TO_STR(MAX_LEN); 00365 // tstring bar = SYMBOL_TO_TSTR(MAX_LEN); 00366 // becomes 00367 // std::string foo = "15"; 00368 // tstring bar = _T("15"); 00369 // 00370 // Note that TO_STR(MAX_LEN) results in "MAX_LEN". The double macro is required in 00371 // order to strinigize the *definition* of a symbol (as opposed to the symbol itself) 00372 #define SYMBOL_TO_STR(x) TO_STR(x) 00373 #define SYMBOL_TO_TSTR(x) TO_TSTR(x) 00374 00375 #endif 00376 00377 #ifdef _WIN32 00378 #define systemtime_t __time64_t 00379 #define getSystemTimeInSeconds() _time64(NULL) 00380 #else 00381 #define systemtime_t time_t 00382 #define getSystemTimeInSeconds() time(NULL) 00383 #endif 00384 00385 #ifndef _WIN32 00386 #ifndef INFINITE 00387 #define INFINITE 0xFFFFFFFF 00388 #endif 00389 #endif 00390 00391 #ifdef _WIN32 00392 #define PATHNAME_DELIMITER '\\' 00393 #define PATHNAME_DELIMITER_STR "\\" 00394 #else 00395 #define PATHNAME_DELIMITER '/' 00396 #define PATHNAME_DELIMITER_STR "/" 00397 #endif 00398 #define URL_URI_DELIMITER '/' 00399 #define URL_URI_DELIMITER_STR "/" 00400 00401 #ifdef _WIN32 00402 #define NEWLINE "\r\n" 00403 #else 00404 #define NEWLINE "\n" 00405 #endif 00406 00407 #if defined(_WIN32) 00408 #define HOSTSFILE_LOCATION _T("drivers\\etc\\hosts") 00409 #else 00410 #define HOSTSFILE_LOCATION _T("/etc/hosts") 00411 #endif 00412 00413 #ifdef _WIN32 00414 #define DebugWriteFile(_handle_,_buffer_,_length_,_refCharsWritten_) \ 00415 WriteFile((_handle_),(_buffer_),(_length_),(_refCharsWritten_),NULL) 00416 #else 00417 #ifndef INVALID_HANDLE_VALUE 00418 #define INVALID_HANDLE_VALUE NULL 00419 #endif 00420 #define DebugWriteFile(_handle_,_buffer_,_length_,_refCharsWritten_) \ 00421 fprintf((_handle_), "%s", (_buffer_)); \ 00422 fflush((_handle_)) 00423 #endif 00424 00425 typedef uint8_t MAC_ADDR[6]; 00426 00427 #if !defined(_WIN32) || defined(_WIN32_WCE) 00428 #ifndef ADDRESS_FAMILY 00429 typedef unsigned short ADDRESS_FAMILY; 00430 #endif 00431 #endif 00432 00433 #if ((defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN) || defined(PLATFORM_LINUX)) && !defined(ANYCONNECT_USE_SNAK) && !defined(PRODUCT_TYPE_SSA) 00434 /* 00435 ** the FIREWALL_SUPPORTED define is used to track the platforms 00436 ** where the firewall feature is supported. This is to avoid repeating the 00437 ** platforms in #ifdef clauses in other files. 00438 ** Also, when Firewall feature expands to other platforms, they only need to be added in 00439 ** one place. 00440 */ 00441 #define FIREWALL_SUPPORTED 00442 #endif 00443 00444 #if !defined(PRODUCT_TYPE_SSA) && ((defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN)) 00445 /* 00446 ** the TRUSTED_NETWORK_DETECTION define is used to track the platforms 00447 ** where Trusted Network Detection is performed. This is to avoid repeating the 00448 ** platforms in #ifdef clauses in other files. 00449 ** Also, when TND support expands to other platforms, they only need to be added in 00450 ** one place. 00451 */ 00452 #define TRUSTED_NETWORK_DETECTION 00453 #endif 00454 00455 #if ((defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN) || defined(TRUSTED_NETWORK_DETECTION)) && !defined(PRODUCT_TYPE_SSA) 00456 /* 00457 ** the LOGIN_UTILITIES_SUPPORTED define is used to track the platforms 00458 ** that support AnyConnect action triggered by user login. This is to avoid 00459 ** repeating the platforms in #ifdef clauses in other files. 00460 ** Also, when login support expands to other platforms, they only need to be added in 00461 ** one place. 00462 */ 00463 #define LOGIN_UTILITIES_SUPPORTED 00464 #endif 00465 00466 #if defined(_WIN32) && !defined(_WIN32_WCE) && !defined(PRODUCT_TYPE_SSA) 00467 /* 00468 ** The DNS_PLUGIN_SUPPORTED define is used to track the platforms where the DNS KDF plugin is 00469 ** available. This is to avoid repeating the platforms in #ifdef clauses in other files. 00470 ** Also, when support expands to other platforms, they only need to be added in one place. 00471 */ 00472 #define DNS_PLUGIN_SUPPORTED 00473 #endif 00474 00475 #if !(defined(PLATFORM_APPLE_SSLVPN) && TARGET_CPU_ARMV6) 00476 /* 00477 ** A bug was discovered in iPhone testing wherein virtual inline functions do 00478 ** not work correctly on ARMv6 processors. To work around this, virtual inline 00479 ** function need to be made standard virtual functions on ARMv6. To prevent 00480 ** differences in runtime behavior, the VIRTUAL_INLINES_SUPPORTED define is used 00481 ** to define some virtual inlines in the header files, letting the functions be 00482 ** defined without the inline type in the cpp file for non-supported platforms. 00483 */ 00484 #define VIRTUAL_INLINES_SUPPORTED 00485 #endif 00486 00487 /* 00488 * When changing the SCRIPTING_SUPPORTED definition, you MUST also update the 00489 * ClientIfcBase.h! We duplicate this definition there due to the manner in 00490 * which we distribute our code to partners; we cannot include this header from 00491 * ClientIfcBase.h. 00492 */ 00493 #if !defined(PLATFORM_APPLE_SSLVPN) && !defined(PLATFORM_ANDROID) 00494 /* 00495 ** the SCRIPTING_SUPPORTED define is used to enable the script manager for launching 00496 ** customer provided scripts on events like connection establishment, completion of 00497 ** disconnect, and captive portal detection. 00498 */ 00499 #define SCRIPTING_SUPPORTED 00500 #endif 00501 00502 #if !defined(PRODUCT_TYPE_SSA) && ((defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN)) 00503 /* 00504 ** the NETWORK_ENVIRONMENT_STATE define is used to track the platforms 00505 ** where NETWORK_ENVIRONMENT_STATE check is performed. This is to avoid repeating the 00506 ** platforms in #ifdef clauses in other files. 00507 ** Also, when NES support expands to other platforms, they only need to be added in 00508 ** one place. 00509 */ 00510 #define NETWORK_ENVIRONMENT_STATE 00511 #endif 00512 00513 00514 #if (defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN) 00515 /* 00516 ** The AUTOMATIC_HEADEND_SELECTION define is used to track the platforms 00517 ** where Automatic Headend Selection is performed. This is to avoid repeating the 00518 ** platforms in #ifdef clauses in other files. 00519 ** Also, when AHS support expands to other platforms, they only need to be added in 00520 ** one place. 00521 */ 00522 #define AUTOMATIC_HEADEND_SELECTION 00523 #endif 00524 00525 #if (defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN) 00526 /* 00527 ** the MUS_HOST_SERVICES define is used to track the platforms 00528 ** where MUS Host Status check is performed. This is to avoid repeating the 00529 ** platforms in #ifdef clauses in other files. 00530 */ 00531 #define MUS_HOST_SERVICES 00532 #endif 00533 00534 // BUGBUG - initially only enable code signing for Windows 00535 #if (defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN) || (defined(PLATFORM_LINUX) && !defined(PLATFORM_LINUX_EMBEDDED_PPC) && !defined(PLATFORM_LINUX_EMBEDDED_ARM)) 00536 /* 00537 ** the CODE_SIGNING_SUPPORTED define is used to track the platforms 00538 ** where code sign verification is support. This is to avoid repeating the 00539 ** platforms in #ifdef clauses in other files. 00540 ** 00541 */ 00542 #define CODE_SIGNING_SUPPORTED 00543 #endif 00544 00545 #if defined(_WIN32) && !defined(_WIN32_WCE) 00546 #define RSA_SECURID_SUPPORTED 00547 #endif 00548 00549 #if defined(_WIN32) && !defined(_WIN32_WCE) 00550 #define SAFEWORD_SOFTOKEN_SUPPORTED 00551 #endif 00552 00553 #if (defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN) || defined(PLATFORM_LINUX) || ( defined(PRODUCT_TYPE_SSA) && defined(APPLE_IOS) ) 00554 /* 00555 ** the IPSEC_SUPPORTED define is used to track the platforms 00556 ** where the IPSec protocol is supported. This is to avoid repeating the 00557 ** platforms in #ifdef clauses in other files. 00558 */ 00559 #define IPSEC_SUPPORTED 00560 #endif 00561 00562 #if ((defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN)) && !defined(ANYCONNECT_USE_SNAK) 00563 /* 00564 ** The IPV6_SUPPORTED define is used to track the platforms 00565 ** where full IPv6 capability is supported. This is to avoid repeating the 00566 ** platforms in #ifdef clauses in other files. 00567 ** Note that this is further narrowed down by method CIPv6Util::IsIPv6FullCapabilitySupported. 00568 */ 00569 #define IPV6_SUPPORTED 00570 #endif 00571 00572 #if (defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN) || defined(PLATFORM_LINUX) || ( defined(PRODUCT_TYPE_SSA) && defined(APPLE_IOS) ) 00573 /* 00574 ** the PLUGIN_PROTOCOL_SUPPORTED define is used to track the platforms 00575 ** where modular protocol Plugins are supported. This is to avoid repeating the 00576 ** platforms in #ifdef clauses in other files. 00577 */ 00578 #define PLUGIN_PROTOCOL_SUPPORTED 00579 #endif 00580 00581 #if defined(_WIN32) && !defined(_WIN32_WCE) && !defined(PRODUCT_TYPE_SSA) 00582 /* 00583 ** The IPSEC_OVER_SSL define is used to track the platforms 00584 ** where the feature "IPsec tunneling over SSL for Oracle" (EDCS-852737) is supported. 00585 ** This is to avoid repeating the platforms in #ifdef clauses in other files. 00586 ** Also, when the support expands to other platforms, they only need to be added in 00587 ** one place. 00588 */ 00589 #define IPSEC_OVER_SSL 00590 #endif 00591 00592 #if (defined(_WIN32) && !defined(_WIN32_WCE)) || defined(PLATFORM_DARWIN) || defined(PLATFORM_LINUX) || defined(APPLE_IOS) 00593 /* 00594 ** the DATA_OBFUSCATING_SUPPORTED define is used to track the platforms 00595 ** where data obfuscation using key exchanges are supported. This is to 00596 ** avoid repeating the platforms in #ifdef clauses in other files. 00597 */ 00598 #define DATA_OBFUSCATING_SUPPORTED 00599 #endif 00600 00601 00602 #if !defined(PLATFORM_APPLE_SSLVPN) && !defined(_WIN32_WCE) && !defined(PRODUCT_TYPE_SSA) 00603 /* 00604 ** the HOSTFILE_MODIFICATION_SUPPORTED define is used to track the platforms 00605 ** where hosts file modification is performed. This is to avoid repeating the 00606 ** platforms in #ifdef clauses in other files. 00607 */ 00608 #define HOSTSFILE_MODIFICATION_SUPPORTED 00609 #endif 00610 00611 #if defined(_WIN32) || defined(_WIN32_WCE) || defined(PLATFORM_DARWIN) || defined(PLATFORM_LINUX) 00612 /* 00613 ** the SCEP_CERTIFICATE_ENROLLMENT_SUPPORTED define is used to track the platforms 00614 ** where SCEP enrollment can be performed. This is to avoid repeating the 00615 ** platforms in #ifdef clauses in other files. 00616 */ 00617 #define SCEP_CERTIFICATE_ENROLLMENT_SUPPORTED 00618 #endif 00619 #if !defined(_WIN32_WCE) && !defined(PLATFORM_ANDROID) && !defined(APPLE_IOS) 00620 /* 00621 ** The SUITEB_SUPPORTED define is used to track the platforms where SuiteB 00622 ** algorithms and certififcates are supported. This is to avoid repeating the 00623 ** platforms in #ifdef clauses in other files. 00624 */ 00625 #define SUITEB_SUPPORTED 00626 #endif 00627 00628 #if (defined(_WIN32) && !defined(_WIN32_WCE)) 00629 /* 00630 ** these XXX_PROFILE_SUPPORTED defines are used to track the platforms where 00631 ** Service Profiles for optional modules are supported. 00632 ** All platforms: VPN 00633 ** Windows: NAM, Telemetry and Web Security 00634 */ 00635 #define NAM_PROFILE_SUPPORTED 00636 #define TELEMETRY_PROFILE_SUPPORTED 00637 #define WEBSEC_PROFILE_SUPPORTED 00638 #elif defined(PLATFORM_DARWIN) 00639 /* 00640 ** OS X: Web Security 00641 */ 00642 #define WEBSEC_PROFILE_SUPPORTED 00643 #endif 00644 00645 #if defined(_WIN32) || defined(PLATFORM_DARWIN) || (defined(PLATFORM_LINUX) && !defined(PLATFORM_ANDROID)) 00646 /* 00647 ** The exportStats call is only supported on the Desktop Platforms, 00648 ** it should not be included or supported if it is not a Desktop Plat 00649 */ 00650 #define EXPORT_STATS_SUPPORTED 00651 #endif 00652 00653 #if (defined(_WIN32) || defined(PLATFORM_DARWIN) || defined(PLATFORM_LINUX)) && !defined(PLATFORM_ANDRIOD) && !defined(PLATFORM_APPLE_SSLVPN) 00654 #define AC_CERTIFICATE_POLICY_SUPPORTED 00655 #endif 00656 00657 #ifndef _TRSTRING 00658 #define _tr(String) String 00659 #define _TRSTRING 00660 #endif 00661 00662 #ifndef _C_MYASSERT 00663 #define C_MYASSERT(e) typedef char __C_MYASSERT__[(e)?1:-1] 00664 #define _C_MYASSERT 00665 #endif 00666 00667 #if defined(PLATFORM_APPLE_SSLVPN) || defined(APPLE_IOS) 00668 #define NETWORK_ORDER_LOOPBACK_INTF_ADDR htonl(0x7f000001) // 127.0.0.1 00669 #endif 00670 00671 #if !defined(BITS_PER_BYTE) 00672 #define BITS_PER_BYTE 8 00673 #endif 00674 00675 #if !defined(_WIN32_WCE) && !defined(PLATFORM_APPLE_SSLVPN) && !defined(PLATFORM_LINUX_EMBEDDED_PPC) && !defined(PLATFORM_WEBOS_ARM) && !defined(PLATFORM_WEBOS_X86) && !defined(PLATFORM_ANDROID) && !defined(APPLE_IOS) 00676 #define FIPS_SUPPORTED 00677 #endif 00678 00679 #if !defined(_WIN32_WCE) && !defined(PLATFORM_APPLE_SSLVPN) && !defined(PLATFORM_LINUX_EMBEDDED_PPC) && !defined(PLATFORM_WEBOS_ARM) && !defined(PLATFORM_WEBOS_X86) && !defined(PLATFORM_ANDROID) && !defined(APPLE_IOS) && !defined(PRODUCT_TYPE_SSA) 00680 #define LEAF_SUPPORTED 00681 #endif 00682 00683 #if !defined(PRODUCT_TYPE_SSA) && ( defined(_WIN32) || ( defined(PLATFORM_LINUX) && !defined(PLATFORM_ANDROID) ) || defined(PLATFORM_DARWIN) ) 00684 #define ENFORCE_MULTIPLE_LOGON 00685 #endif 00686 00687 #if !defined(PLATFORM_ANDROID) // More platforms need to be added 00688 #define WIDE_CHAR_SUPPORTED 00689 #endif 00690 00691 #if defined(_WIN32) && !defined(PRODUCT_TYPE_SSA) 00692 #define TUNNEL_PROXY_SETTINGS_SUPPORTED 00693 #endif 00694 00695 /* 00696 ** Public Proxy support is only implemented on Windows and Linux desktop platforms 00697 */ 00698 #if (defined(_WIN32) || defined(PLATFORM_LINUX)) && !defined(PRODUCT_TYPE_SSA) 00699 #define PUBLIC_PROXY_SUPPORTED 00700 #endif 00701 00702 /* 00703 ** NTLM support is only implemented on Windows desktop platforms 00704 */ 00705 #if defined(_WIN32) && defined(PUBLIC_PROXY_SUPPORTED) 00706 #define PROXYAUTH_NTLM_SUPPORTED 00707 #endif 00708 00709 #if defined(PLATFORM_ANDROID) || (defined(PRODUCT_TYPE_SSA) && defined(APPLE_IOS)) 00710 #define IMPORT_API_SUPPORTED 00711 #endif 00712 00713 #if defined(PRODUCT_TYPE_SSA) && !defined(PLATFORM_ANDROID) 00714 /* 00715 ** This serves to tell the IPsec plugin interface to explicitly 00716 ** exclude it's global namespace entry points, leaving the only 00717 ** plugin interface as a set of static class methods, which the 00718 ** loading code will look for directly. 00719 */ 00720 #define IPSEC_AS_INTERNAL_MODULE 00721 #endif 00722 00723 #if defined(PLATFORM_ANDROID) // More platforms need to be added 00724 #define dynamic_cast reinterpret_cast 00725 #endif 00726 00727 #if defined(PRODUCT_TYPE_SSA) && defined(APPLE_IOS) && !defined(PLATFORM_APPLE_SSLVPN) 00728 #define CONFIGURE_REMOTE_WAKEUP_SUPPORTED 00729 #endif 00730 00731 /* 00732 ** The SMARTCARD_REMOVAL_SUPPORTED define is used to track the platforms where smartcard 00733 ** removal monitoring is supported. This is to avoid repeating the 00734 ** platforms in #ifdef clauses in other files. 00735 */ 00736 #if defined(_WIN32) 00737 #define SMARTCARD_REMOVAL_SUPPORTED 00738 #endif 00739 00740 #if defined(PLATFORM_LINUX) && !defined(ANYCONNECT_USE_SNAK) && !defined(PRODUCT_TYPE_SSA) 00741 /* 00742 ** The CIRCUMVENT_HOST_FILTERING_SUPPORTED define is used to track the platforms 00743 ** where AnyConnect can control whether or not pre-existing host filtering is 00744 ** circumvented upon applying AnyConnect filtering (only applicable to split-tunneling). 00745 */ 00746 #define CIRCUMVENT_HOST_FILTERING_SUPPORTED 00747 #endif 00748 00749 #if defined(PLUGIN_PROTOCOL_SUPPORTED) && !defined(PRODUCT_TYPE_SSA) 00750 #if (defined(_WIN32) && !defined(_WIN32_WCE)) 00751 // support Service Control Plugins if defined 00752 #define SERVICE_PLUGIN 00753 // support Telemetry Plugin if defined 00754 #define TELEMETRY_PLUGIN 00755 // support PhoneHome Plugin if defined 00756 #define PHONEHOME_PLUGIN 00757 #elif defined(PLATFORM_DARWIN) 00758 // support Service Control Plugins if defined 00759 #define SERVICE_PLUGIN 00760 // support PhoneHome Plugin if defined 00761 #define PHONEHOME_PLUGIN 00762 #elif defined(PLATFORM_LINUX) 00763 #define PHONEHOME_PLUGIN 00764 #endif 00765 00766 #endif 00767 /* 00768 * Platforms that support ACIDEX. 00769 */ 00770 #if defined(_WIN32) || defined(PLATFORM_DARWIN)|| defined(PLATFORM_LINUX) 00771 #define ACIDEX_SUPPORTED 00772 #endif 00773 00774 /* 00775 * TLS 1.2 is not supported in 3.x versions of AnyConnect. Support shall begin in the 4.0 release. 00776 */ 00777 #if defined(ANYCONNECT_RELEASE_4_OR_HIGHER) 00778 #define TLS_1_2_SUPPORTED 00779 #endif 00780 00781 /* END OF MACRO HELL */ 00782 #endif /*__GENDEFS_H*/