Issue #558
strongswan mac client won't work
Description
Hi all,
I use the strongswan-5.1.2.tar.bz2 source code and copy the mac os client from github (/src/frontend/osx/*).
And complier with below configure option and build successfully.
CFLAGS="-O2 -Wall -Wno-format -Wno-pointer-sign -Wno-deprecated-declarations" ./configure --enable-monolithic --disable-shared --enable-static --disable-defaults --enable-openssl --enable-kernel-libipsec --enable-kernel-pfroute --enable-eap-mschapv2 --enable-eap-identity --enable-eap-md5 --enable-pkcs1 --enable-socket-default --enable-osx-attr --enable-xauth-generic --enable-gcm --enable-ccm --enable-ctr --enable-keychain --enable-nonce --enable-charon --enable-ikev1 --enable-ikev2 --enable-kernel-pfkey --with-lib-prefix=/opt/local
But I try to run the executable binary file, it throws below error messages.
00[LIB] created TUN device: utun0 00[CFG] loaded 227 certificates from /System/Library/Keychains/SystemRootCertificates.keychain 00[CFG] loaded 5 certificates from /Library/Keychains/System.keychain 00[DMN] Starting charon-xpc IKE daemon (strongSwan 5.1.2, Darwin 13.1.0, x86_64) 00[JOB] spawning 16 worker threads 05[DMN] thread 5 received 11 05[LIB] dumping 14 stack frame addresses: 05[LIB] /usr/lib/system/libsystem_platform.dylib @ 0x00007fff8e7c8000 (_sigtramp+0x1a) [0x00007fff8e7cb5aa] 05[LIB] -> _sigtramp (in libsystem_platform.dylib) + 26 05[LIB] 1 ??? 0x0000000000000000 0x0 + 0 05[LIB] /Users/tony/Documents/strongswan-5.1.2/src/frontends/osx/build/Release/./org.strongswan.charon-xpc @ 0x000000010830f000 (__set_handler_block_invoke+0x54) [0x00000001083aa56b] 05[LIB] -> __set_handler_block_invoke (in org.strongswan.charon-xpc) (xpc_dispatch.c:298) 05[LIB] /usr/lib/system/libxpc.dylib @ 0x00007fff8d571000 (_xpc_connection_call_event_handler+0x3a) [0x00007fff8d57c5cc] 05[LIB] -> _xpc_connection_call_event_handler (in libxpc.dylib) + 58 05[LIB] /usr/lib/system/libxpc.dylib @ 0x00007fff8d571000 (_xpc_connection_mach_event+0x438) [0x00007fff8d57adcb] 05[LIB] -> _xpc_connection_mach_event (in libxpc.dylib) + 1080 05[LIB] /usr/lib/system/libdispatch.dylib @ 0x00007fff86950000 (_dispatch_client_callout4+0x9) [0x00007fff86954afe] 05[LIB] -> _dispatch_client_callout4 (in libdispatch.dylib) + 9 05[LIB] /usr/lib/system/libdispatch.dylib @ 0x00007fff86950000 (_dispatch_mach_cancel_invoke+0x32) [0x00007fff8695765c] 05[LIB] -> _dispatch_mach_cancel_invoke (in libdispatch.dylib) + 50 05[LIB] /usr/lib/system/libdispatch.dylib @ 0x00007fff86950000 (_dispatch_mach_invoke+0x25c) [0x00007fff86954860] 05[LIB] -> _dispatch_mach_invoke (in libdispatch.dylib) + 604 05[LIB] /usr/lib/system/libdispatch.dylib @ 0x00007fff86950000 (_dispatch_async_redirect_invoke+0x3f) [0x00007fff869557a4] 05[LIB] -> _dispatch_async_redirect_invoke (in libdispatch.dylib) + 63 05[LIB] /usr/lib/system/libdispatch.dylib @ 0x00007fff86950000 (_dispatch_client_callout+0x8) [0x00007fff869512ad] 05[LIB] -> _dispatch_client_callout (in libdispatch.dylib) + 8 05[LIB] /usr/lib/system/libdispatch.dylib @ 0x00007fff86950000 (_dispatch_root_queue_drain+0x146) [0x00007fff8695309e] 05[LIB] -> _dispatch_root_queue_drain (in libdispatch.dylib) + 326 05[LIB] /usr/lib/system/libdispatch.dylib @ 0x00007fff86950000 (_dispatch_worker_thread2+0x28) [0x00007fff86954193] 05[LIB] -> _dispatch_worker_thread2 (in libdispatch.dylib) + 40 05[LIB] /usr/lib/system/libsystem_pthread.dylib @ 0x00007fff838fa000 (_pthread_wqthread+0x13a) [0x00007fff838fcef8] 05[LIB] -> _pthread_wqthread (in libsystem_pthread.dylib) + 314 05[LIB] /usr/lib/system/libsystem_pthread.dylib @ 0x00007fff838fa000 (start_wqthread+0xd) [0x00007fff838fffb9] 05[LIB] -> start_wqthread (in libsystem_pthread.dylib) + 13 05[DMN] killing ourself, received critical signal Abort trap: 6
My development environments are mac 10.9/xcode 5.1 and mac 10.7/xcode 4.6.3, and all encounter the same problem.
Can you help me to resolve this problem.
Thanks.
Related issues
History
#1 Updated by Tobias Feldhaus over 11 years ago
I don't know if its related but the newest Mac OS 10.9.2 version seems to have issues with the strongswan (5.1.1-3) gui app. Most of the users get the following stacktrace:
dumping 10 stack frame addresses: /usr/lib/system/libsystem_platform.dylib @ 0x00007fff80c4a000 (_sigtramp+0x1a) [0x00007fff80c4d5aa] -> _sigtramp (in libsystem_platform.dylib) + 26 1 ??? 0x0000000000000000 0x0 + 0 /Library/PrivilegedHelperTools/org.strongswan.charon-xpc @ 0x0000000109975000 (ike_sa_create+0x2393) [0x00000001099d4833] -> 0x000000010005f833 (in org.strongswan.charon-xpc) + 291 /Library/PrivilegedHelperTools/org.strongswan.charon-xpc @ 0x0000000109975000 (ike_sa_create+0x3286) [0x00000001099d5726] -> 0x0000000100060726 (in org.strongswan.charon-xpc) + 86 /Library/PrivilegedHelperTools/org.strongswan.charon-xpc @ 0x0000000109975000 (controller_create+0xd2f) [0x00000001099bc1cf] -> 0x00000001000471cf (in org.strongswan.charon-xpc) + 159 /Library/PrivilegedHelperTools/org.strongswan.charon-xpc @ 0x0000000109975000 (processor_create+0x647) [0x0000000109991827] -> 0x000000010001c827 (in org.strongswan.charon-xpc) + 359 /Library/PrivilegedHelperTools/org.strongswan.charon-xpc @ 0x0000000109975000 (strongswan_thread_create+0x1e5) [0x00000001099952f5] -> 0x00000001000202f5 (in org.strongswan.charon-xpc) + 117 /usr/lib/system/libsystem_pthread.dylib @ 0x00007fff8a4d8000 (_pthread_body+0x8a) [0x00007fff8a4d9899] -> _pthread_body (in libsystem_pthread.dylib) + 138 /usr/lib/system/libsystem_pthread.dylib @ 0x00007fff8a4d8000 (_pthread_struct_init+0x0) [0x00007fff8a4d972a] -> _pthread_struct_init (in libsystem_pthread.dylib) + 0 /usr/lib/system/libsystem_pthread.dylib @ 0x00007fff8a4d8000 (thread_start+0xd) [0x00007fff8a4ddfc9] -> thread_start (in libsystem_pthread.dylib) + 13 killing ourself, received critical signal
#3 Updated by Tobias Brunner over 11 years ago
- Description updated (diff)
- Assignee set to Martin Willi
#4 Updated by Tobias Brunner over 11 years ago
- Related to Bug #456: StrongSwan client for OS X crashes added
#5 Updated by Tobias Brunner over 11 years ago
The crash reported by Tony is probably not related to #456 after all. According to the man page for xpc_connection_create_mach_service() such services can't be created dynamically:
Important: New service names may NOT be dynamically registered using
xpc_connection_create_mach_service(). Only launchd jobs may listen on certain service names, and any
service name that the job wishes to listen on must be declared in its launchd.plist(5). XPC may make
allowances for dynamic name registration in debug scenarios, but these allowances absolutely will NOT
be made in the production scenario.
So charon-xpc
will work when started via launchd and it may also work in Xcode (i.e. in a debugging scenario) but running it directly from a terminal is probably not possible due to this.
#6 Updated by Tobias Brunner about 10 years ago
- Status changed from New to Closed
- Assignee changed from Martin Willi to Tobias Brunner
- Priority changed from High to Normal
- Resolution set to No feedback