]> git.ipfire.org Git - thirdparty/strongswan.git/commitdiff
android: Only allow DNS queries for the configured hostname
authorTobias Brunner <tobias@strongswan.org>
Wed, 16 Jul 2014 14:20:00 +0000 (16:20 +0200)
committerTobias Brunner <tobias@strongswan.org>
Tue, 22 Jul 2014 09:10:36 +0000 (11:10 +0200)
src/frontends/android/jni/libandroidbridge/backend/android_service.c

index 73738c22ed78a0adf8ea456269bdb1867c1c6484..fb8f93311e24b3bde8dfcbc4d51130a18f5b93cb 100644 (file)
@@ -749,6 +749,8 @@ android_service_t *android_service_create(android_creds_t *creds, char *type,
                .type = type,
                .tunfd = -1,
        );
+       /* only allow queries for the VPN gateway */
+       this->dns_proxy->add_hostname(this->dns_proxy, gateway);
 
        charon->bus->add_listener(charon->bus, &this->public.listener);