Commit Graph
15415 Commits
Author SHA1 Message Date
Tobias Brunner a305419b40 Trusted CA certificates are loaded and cached by a static singleton 2012-08-13 11:00:24 +02:00
Tobias Brunner 40dfe8f1d8 Remove restriction to portrait orientation 2012-08-13 11:00:24 +02:00
Tobias Brunner 3a32ba7111 Use Holo as theme 2012-08-13 11:00:24 +02:00
Tobias Brunner da9bb5044f Make click events on the profile list available to the Activity
If the Activity this fragment is placed in implements the provided interface
it is notified about clicks on any of the profiles.
2012-08-13 11:00:09 +02:00
Tobias Brunner e4ef4c9877 Merge branch 'android-ndk'
This branch comes with some preliminary changes for the user-land IPsec
implementation and the Android App.

One important change is that the UDP ports used by the socket-default plugin
were made configurable (either via ./configure or strongswan.conf).
Also, the plugin does randomly allocate a port if it is configured to 0,
which is useful for client implementations.  A consequence of these
changes is that the local UDP port used when creating ike_cfg_t objects has
to be fetched from the socket.
2012-08-13 10:45:39 +02:00
Tobias Brunner 000668d308 Doxygen fix 2012-08-11 16:50:22 +02:00
Tobias Brunner 3b891b9e5b Avoid problems with Doxygen by adding warn_unused_result attribute at the end of method signatures 2012-08-11 16:48:09 +02:00
Tobias Brunner 2c93a214aa Add warn_unused_result attributes to rng_(get|allocate)_bytes_not_zero
Also fixed Doxygen comments.
2012-08-11 16:30:27 +02:00
Tobias Brunner 9ede42e112 Documentation fixes regarding xauth-pam/eap-gtc plugins 2012-08-11 16:05:05 +02:00
Tobias Brunner c6b736b9f5 Use a contextual action bar to edit and delete selected VPN profiles 2012-08-11 15:10:35 +02:00
Tobias Brunner a3e2f127dc Provide a menu with options to save VPN profiles
The ID of the updated/inserted profile is sent back to the activity that
started the detail view.
2012-08-11 15:10:35 +02:00
Tobias Brunner c2e427c287 The list fragment uses a menu to provide an option to add new VPN profiles 2012-08-11 15:10:34 +02:00
Tobias Brunner 56a922b2ed Added an activity to edit basic VPN profile details
Already load existing data based on extra data delivered with the
Intent, no saving and CA certificate handling yet.
2012-08-11 15:10:34 +02:00
Tobias Brunner 0458ac7cbc Show list fragment in main activity 2012-08-11 15:10:34 +02:00
Tobias Brunner 7329618cc2 Fragment added to list the VPN profiles 2012-08-11 15:10:34 +02:00
Tobias Brunner 03a5a63c03 Added a custom adapter and layout to display VPN profiles in a ListView 2012-08-11 15:10:34 +02:00
Tobias Brunner d799cbf676 Added class to simplify access to database of VPN profiles 2012-08-11 15:10:33 +02:00
Tobias Brunner 3d9127da61 Added class to move around VPN profiles in the Android App 2012-08-11 15:10:33 +02:00
Tobias Brunner b17b495f2e Replaced launcher icon with a more appropriate one 2012-08-11 15:10:33 +02:00
Martin Willi a63192479d If _POSIX_SPIN_LOCKS is defined as -1, it is not available 2012-08-10 17:02:46 +02:00
Martin Willi 922fb29f89 If vstr printf functions are #defined, undef them before redefinition
At least Mountain Lion seems to have them #defined to secure _chk
variants.
2012-08-10 17:02:05 +02:00
Martin Willi cd55a3cb77 Use actual daemon name to enable XAuth/PSK with aggressive mode 2012-08-10 11:53:18 +02:00
Martin Willi 3423b3a88a Add xauth-pam/eap-gtc NEWS 2012-08-10 11:50:44 +02:00
Martin Willi 27128c1e32 EAP-GTC can use any XAuth backend, including xauth-pam
This makes EAP-GTC a generic plain password authentication method,
as it is used with XAuth. Instead of verifying credentials with
PAM, any backend can be configured. The default is xauth-pam,
providing the same functionality as EAP-GTC in strongSwan 4.x.
2012-08-10 10:43:44 +02:00
Martin Willi b9e4916321 Add xauth-pam, an XAuth backend verifying credentials with PAM 2012-08-10 10:43:44 +02:00
Martin Willi 0bac49b0a9 Add getspnam_r() to leak detective whitelist 2012-08-10 10:43:44 +02:00
Andreas Steffen da21793679 make max_message_size parameter consistent with similar options 2012-08-09 14:11:08 +02:00
Martin Willi 02cabd0f26 Check if TLS handshake received Finished before processing application data 2012-08-09 12:10:41 +02:00
Tobias Brunner 441dde9ee9 Moved main Activity to ui sub-package
Also force portrait orientation.
2012-08-08 15:41:04 +02:00
Tobias Brunner 8bf3027643 Moved CharonVpnService to logic sub-package 2012-08-08 15:41:04 +02:00
Tobias Brunner 6f11e94134 Global charonservice_t object added to libandroidbridge
This is later used to call Java methods on CharonVpnService via JNI.
2012-08-08 15:41:04 +02:00
Tobias Brunner f83f65be08 Added functions to attach/detach native threads to the JVM
Even though native threads are automatically detached from the JVM with
help of a thread-local destructor it is recommended to detach as soon as
possible as local JNI references are not freed until a thread detaches.
2012-08-08 15:41:04 +02:00
Tobias Brunner cb887af4cf Moved JNI helper macros to a separate file
Also initialize a reference to the CharonVpnService class during
JNI_OnLoad, which allows us later to call methods from C to Java.
2012-08-08 15:41:03 +02:00
Tobias Brunner d62d5d7c2e Use strongSwan logo as icon
Due to the transparency and black font this is probably not optimal yet.
2012-08-08 15:41:03 +02:00
Tobias Brunner b6a071514a Fixed ip_packet_t if IPv6 is not available 2012-08-08 15:41:03 +02:00
Tobias Brunner 34400edc37 Added utility class to create TUN devices
Currently works only on Linux.
2012-08-08 15:41:03 +02:00
Tobias Brunner a113d7f29b Added IPsec processor which is responsible for handling in- and outbound packets
Two callbacks can be registered that get called when new inbound plaintext and
outbound ESP packets have been processed. Inbound ESP and outbound plaintext
packets can be queued for processing with two other methods.
2012-08-08 15:41:03 +02:00
Tobias Brunner b37758c41e Represent the payload of an ESP packet as ip_packet_t instead of a chunk_t 2012-08-08 15:41:03 +02:00
Tobias Brunner 2e1a19136d IPsec policies can be looked up based on an IP packet 2012-08-08 15:41:03 +02:00
Tobias Brunner 2dd47c2442 ip_packet_t parses the header of IP packets 2012-08-08 15:41:03 +02:00
Tobias Brunner ed1f0c234f Order IPsec policies by a pseudo-priority based on the traffic selectors
This allows a simple lookup, i.e. just use the first policy that matches
a given IP packet.
2012-08-08 15:41:03 +02:00
Tobias Brunner f1b4238311 Implemented a checkout/checkin mechanism for IPsec SAs
SAs can only be checked out by a single thread and all other threads
block until the SA is checked in again.
2012-08-08 15:41:03 +02:00
Tobias Brunner 7000cf11b1 IPsec policy manager added
This version only provides the very simplest management functions.
2012-08-08 15:41:03 +02:00
Tobias Brunner 3b8276b405 Method added to easily compare IPsec policies 2012-08-08 15:41:03 +02:00
Tobias Brunner 9a11bc09bd Class representing an IPsec policy added 2012-08-08 15:41:03 +02:00
Tobias Brunner e6cfd527df Schedule and relay expiration events for created IPsec SAs 2012-08-08 15:41:03 +02:00
Tobias Brunner b50f56f326 Added class to relay IPsec events (like expiration) to listeners
Currently, only expiration of IPsec SAs is supported.  Later other events
for e.g. acquires or changed NAT endpoints could be added.
2012-08-08 15:41:03 +02:00
Tobias Brunner 914479370e Added IPsec SA manager 2012-08-08 15:41:03 +02:00
Tobias Brunner 9f7e1899a9 Add methods to easily compare IPsec SAs 2012-08-08 15:41:02 +02:00
Tobias Brunner f9b0c05475 Class representing an IPsec SA added
The IPsec SA also manages the respective ESP context.
2012-08-08 15:41:02 +02:00