Now wtmp_init() does try to lookup the uid for "username" and the gid for
"groupname" if configured and - if successfull - chown the wtmp file to this
combination.
(The lookup of uid/gid is neccessary here as 'context->c0' is no yet
initialized at the point wtmp_init() is called.)
Sign
Hi!
This is an initial attempt to let OpenVPN 2.1 write a wtmp log of all
connections including the username, it's VPN IP and the real remote IP
the user connected from.
This provides an OpenVPN admin with a simple database of all connections
of his VPN servers and the possibility to easily see
Signed-off-by: Maximilian Wilhelm
---
Makefile.am |3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 36e2cf9..6384857 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -94,7 +94,8 @@ openvpn_SOURCES = \
status.c status.h \
syshea
Signed-off-by: Maximilian Wilhelm
---
multi.c | 10 +++---
1 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/multi.c b/multi.c
index 2c23a44..5d8c80e 100644
--- a/multi.c
+++ b/multi.c
@@ -462,7 +462,9 @@ multi_close_instance (struct multi_context *m,
dmsg (D_MULTI_DEBUG, "M
--log-wtmp server_id [file] : Enable logging to wtmp file using the two digit
server_id a prefix for the utmp line. Optionally you can
write
to an own wtmp file. (Default is /var/log/ovpnwtmp.
---
options.c | 31 +++
options.
Signed-off-by: Maximilian Wilhelm
---
multi.c | 16
1 files changed, 16 insertions(+), 0 deletions(-)
diff --git a/multi.c b/multi.c
index fa924f1..2c23a44 100644
--- a/multi.c
+++ b/multi.c
@@ -42,6 +42,10 @@
#include "forward-inline.h"
+#ifdef ENABLE_WTMP
+#include "wtmp.
Now every utmp line will look like "ovpn%d-%s" where %d are the two last
digits of the server_id and %s some chars of the session_id (as many as
fit into the remaining space in 'ut_line'.
This provides the ability to let at most 100 OpenVPN instances on one single
maschine write to the s
Signed-off-by: Maximilian Wilhelm
---
wtmp.c | 333
wtmp.h | 27 +
2 files changed, 360 insertions(+), 0 deletions(-)
create mode 100644 wtmp.c
create mode 100644 wtmp.h
diff --git a/wtmp.c b/wtmp.c
new file mode 100644
in
This change introduces the ability to figure out as which user OpenVPN will
run after dropping privileges. This is very usefull when creating the wtmp
file, which by default is owned by root resulting in OpenVPN not being able
to write to it.
So now the owner and group can be changed to
On July, I asked on the user-list how to obtain the certificate serial
number of an active client:
http://thread.gmane.org/gmane.network.openvpn.user/19913
just in case sombody needs it, you'll find a two-line-patch underneath.
I get now in my log:
VERIFY OK: depth=0, serial=79,
emailAddress=
On July, I asked on the user-list how to obtain the certificate serial
number of an active client:
http://thread.gmane.org/gmane.network.openvpn.user/19913
just in case sombody needs it, you'll find a two-line-patch underneath.
I get now in my log:
VERIFY OK: depth=0, serial=79,
emailAddress=pac
11 matches
Mail list logo