summaryrefslogtreecommitdiff
path: root/accel-pppd/ctrl/l2tp
diff options
context:
space:
mode:
authorDmitry Kozlov <xeb@mail.ru>2016-07-11 09:47:04 +0300
committerDmitry Kozlov <xeb@mail.ru>2016-07-11 09:47:04 +0300
commite0cca4344f70b9c9e23e3c6a7e17c8e93c765184 (patch)
tree1068654b025b2e24c983d99776696ad889a0c138 /accel-pppd/ctrl/l2tp
parent6fb04941ca41312909208938bfac4f753d3c277c (diff)
downloadaccel-ppp-xebd-e0cca4344f70b9c9e23e3c6a7e17c8e93c765184.tar.gz
accel-ppp-xebd-e0cca4344f70b9c9e23e3c6a7e17c8e93c765184.zip
implemented support for network namespace
This is done using radius attribute NAS-Port-Id. The new format of this attribute is NAS-Port-Id=[ns/][name]. Namespaces must be created malually by "ip netns add ..." command
Diffstat (limited to 'accel-pppd/ctrl/l2tp')
-rw-r--r--accel-pppd/ctrl/l2tp/l2tp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/accel-pppd/ctrl/l2tp/l2tp.c b/accel-pppd/ctrl/l2tp/l2tp.c
index 76c679c..5d9041f 100644
--- a/accel-pppd/ctrl/l2tp/l2tp.c
+++ b/accel-pppd/ctrl/l2tp/l2tp.c
@@ -255,7 +255,8 @@ static inline int nsnr_cmp(uint16_t ns, uint16_t nr)
static void l2tp_ctx_switch(struct triton_context_t *ctx, void *arg)
{
- net = &def_net;
+ struct ap_session *s = arg;
+ net = s->net;
log_switch(ctx, arg);
}