aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--manage.c6
-rw-r--r--manage.h3
-rw-r--r--management/management-notes.txt13
-rw-r--r--multi.c2
-rw-r--r--options.c2
-rw-r--r--version.m42
6 files changed, 22 insertions, 6 deletions
diff --git a/manage.c b/manage.c
index a9878c6..cff4348 100644
--- a/manage.c
+++ b/manage.c
@@ -2115,9 +2115,13 @@ management_notify_client_needing_auth (struct management *management,
void
management_connection_established (struct management *management,
- struct man_def_auth_context *mdac)
+ struct man_def_auth_context *mdac,
+ const struct env_set *es)
{
mdac->flags |= DAF_CONNECTION_ESTABLISHED;
+ msg (M_CLIENT, ">CLIENT:ESTABLISHED,%lu", mdac->cid);
+ man_output_extra_env (management);
+ man_output_env (es, true);
}
void
diff --git a/manage.h b/manage.h
index 94ec639..66fb7d1 100644
--- a/manage.h
+++ b/manage.h
@@ -355,7 +355,8 @@ void management_notify_client_needing_auth (struct management *management,
const struct env_set *es);
void management_connection_established (struct management *management,
- struct man_def_auth_context *mdac);
+ struct man_def_auth_context *mdac,
+ const struct env_set *es);
void management_notify_client_close (struct management *management,
struct man_def_auth_context *mdac,
diff --git a/management/management-notes.txt b/management/management-notes.txt
index 6e721de..45bfda4 100644
--- a/management/management-notes.txt
+++ b/management/management-notes.txt
@@ -770,7 +770,16 @@ CLIENT notification types:
>CLIENT:ENV,...
>CLIENT:ENV,END
-(2) Notify existing client disconnection. The environmental variables passed
+(2) Notify successful client authentication and session initiation.
+ Called after CONNECT.
+
+ >CLIENT:ESTABLISHED,{CID}
+ >CLIENT:ENV,name1=val1
+ >CLIENT:ENV,name2=val2
+ >CLIENT:ENV,...
+ >CLIENT:ENV,END
+
+(3) Notify existing client disconnection. The environmental variables passed
are equivalent to those that would be passed to a --client-disconnect
script.
@@ -780,7 +789,7 @@ CLIENT notification types:
>CLIENT:ENV,...
>CLIENT:ENV,END
-(3) Notify that a particular virtual address or subnet
+(4) Notify that a particular virtual address or subnet
is now associated with a specific client.
>CLIENT:ADDRESS,{CID},{ADDR},{PRI}
diff --git a/multi.c b/multi.c
index 6704789..ea6ae93 100644
--- a/multi.c
+++ b/multi.c
@@ -1698,7 +1698,7 @@ multi_connection_established (struct multi_context *m, struct multi_instance *mi
#ifdef MANAGEMENT_DEF_AUTH
if (management)
- management_connection_established (management, &mi->context.c2.mda_context);
+ management_connection_established (management, &mi->context.c2.mda_context, mi->context.c2.es);
#endif
gc_free (&gc);
diff --git a/options.c b/options.c
index e5cc0f2..9ca146f 100644
--- a/options.c
+++ b/options.c
@@ -795,6 +795,8 @@ setenv_settings (struct env_set *es, const struct options *o)
setenv_int (es, "verb", o->verbosity);
setenv_int (es, "daemon", o->daemon);
setenv_int (es, "daemon_log_redirect", o->log);
+ setenv_unsigned (es, "daemon_start_time", time(NULL));
+ setenv_int (es, "daemon_pid", openvpn_getpid());
#ifdef ENABLE_CONNECTION
if (o->connection_list)
diff --git a/version.m4 b/version.m4
index 132e6cd..e0921bf 100644
--- a/version.m4
+++ b/version.m4
@@ -1,5 +1,5 @@
dnl define the OpenVPN version
-define(PRODUCT_VERSION,[2.1_rc15c])
+define(PRODUCT_VERSION,[2.1_rc15d])
dnl define the TAP version
define(PRODUCT_TAP_ID,[tap0901])
define(PRODUCT_TAP_WIN32_MIN_MAJOR,[9])