summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-05-081.7.4 releaseDmitry Kozlov
* fixed various bugs * introduced accel-cmd program * ippool: impelented persistance * radius: implemented default-realm option * radius: proper handling of Framed-IP-Address=255.255.255.254 * shaper: time range and other fixes * shaper: implemented mtu option * net-snmp: fixed run out of FD_SETSIZE
2014-04-29net-snmp: unshare file descriptors namespaceGuillaume Nault
Use unshare(CLONE_FILES) to create a local file descriptors namespace for the SNMP thread. This is similar to what was done in bf5340 'net-snmp: run snmp in "special" thread', but without calling clone() directly. So the net-snmp plugin keeps running in a regular pthread. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2014-04-29Revert "net-snmp: run snmp in "special" thread"Guillaume Nault
This reverts commit f2774e5a02d29de71eb64a64565b23090b6f6c5e. snmp_thread() needs to be run as regular thread to allow Valgrind analysis. Using a different namespace for file desciptors will be done later on using unshare(). Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2014-04-14net-snmp: run snmp in "special" threadDmitry Kozlov
NET-SNMP is built on top of stale file descriptor multiplexing mechanism (select) which prevents to use descriptors with number >= 1024. Due to accel-ppp uses a lots of descriptors NET-SNMP easy overflows this limit and fails and even may crash whole accel-ppp process. This patch runs snmp in special thread which does not share file descritor table with main process, so it can use less descriptors and live in __FD_SETSIZE limit. Signed-off-by: Dmitry Kozlov <xeb@mail.ru>
2014-02-08increase size of buffer for netlink messagesDmitry Kozlov
Signed-off-by: Dmitry Kozlov <xeb@mail.ru> Conflicts: accel-pppd/libnetlink/ipset.c accel-pppd/libnetlink/iputils.c
2014-02-08pppoe: check for tag format validity in PADR messagesGuillaume Nault
Avoid parsing inconsistent PPPoE tags when handling PADR. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2014-02-08ppp: don't unconditionaly load pppoe/pptp/l2tp modules, fixes false start ↵Vladislav Grishenko
warning if they're running already Signed-off-by: Vladislav Grishenko <themiron@mail.ru>
2013-11-07shaper: add mtu optionDmitry Kozlov
Signed-off-by: Dmitry Kozlov <xeb@mail.ru>
2013-11-07shaper: fixed many race conditionsDmitry Kozlov
2013-11-02shaper: fixed socket leakKozlov Dmitry
Close netlink socket in remove_limiter function. Signed-off-by: Kozlov Dmitry <xeb@mail.ru>
2013-11-02shaper: remove garbage (fixed sigsegv in 'shaper restore all')Kozlov Dmitry
Signed-off-by: Kozlov Dmitry <xeb@mail.ru>
2013-10-25shaper: check for range overlaps before adjusting range timesDmitry Kozlov
Fixes detection of range everlaps (time range end time is equal to start time of other range), which prevents starting range end timer. Signed-off-by: Dmitry Kozlov <xeb@mail.ru>
2013-10-25shaper: fixed invalid reference counting (caused unexpected removal of ↵Dmitry Kozlov
internal structure) shaper: do not start time range end timer if end time is equal to start time of other range Signed-off-by: Dmitry Kozlov <xeb@mail.ru>
2013-10-25radius: properly handle send failuresDmitry Kozlov
Signed-off-by: Dmitry Kozlov <xeb@mail.ru>
2013-10-23radius: skip vendor specific attributes when searching session for DM/CoADmitry Kozlov
This fixes invalid assosiation vendor specific Cisco-AVPair to Username attribute which both have same id and prevents to find sessions in some circumstances. Signed-off-by: Dmitry Kozlov <xeb@mail.ru>
2013-09-03snmp: properly terminate snmp threadDmitry Kozlov
2013-08-27shaper: fixed possible race during changing time rangeKozlov Dmitry
2013-08-27Revert "shaper: fixed possible race during changing time range"Kozlov Dmitry
This reverts commit 2829895b32d1b5b8c46027dfb4238f22305d695c.
2013-08-27shaper: fixed possible race during changing time rangeKozlov Dmitry
2013-08-15triton: do not call context close if it is marked as need free (f.e. context ↵Dmitry Kozlov
already called triton_context_unregister)
2013-08-14radius: don't assign address if Framed-IP-Address=255.255.255.254Kozlov Dmitry
2013-07-24triton: Fix race upon terminationGuillaume Nault
The triton_terminate() function works by setting the need_close flag of each triton context, then queues this context for execution by a triton thread if not already running. But if the context is already being run by a triton thread, it may not notice that its need_close flag has been updated (this flag is only checked at the beginning of ctx_thread()). So if no other event wakes up that context (i.e. if ctx_thread() isn't run again), it will never terminate. This patch moves the need_close flag check at the end of ctx_thread() so that a triton context can take the need_close flag into account event if it's updated while running. The context spinlock is also used to protect the need_close flag as it is concurrently updated by triton_terminate(). Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2013-07-05auth_chap: fixed incorrect check for received buffer sizeDmitry Kozlov
2013-06-30mempool: set/check magic only if MEMDEBUG definedDmitry Kozlov
2013-06-14Merge branch '1.7' of ssh://git.code.sf.net/p/accel-ppp/code into 1.7Kozlov Dmitry
2013-06-14connlimit: Fix size of memcpy() for MAC addressGuillaume Nault
The 'hw' parameter of cl_key_from_mac() is actually a pointer, so 'key.hw' must be used instead to compute the size of the MAC address. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2013-06-07ppp: handle LCP DiscardReqKozlov Dmitry
2013-05-14ippool: add cli command to remove persist entriesKozlov Dmitry
2013-04-11Merge branch '1.7' of ssh://git.code.sf.net/p/accel-ppp/code into 1.7Kozlov Dmitry
2013-04-11radius: implemented default-realm optionKozlov Dmitry
2013-03-18ippool: impelented persistanceKozlov Dmitry
2013-02-04build: Set ACCEL_PPP_VERSION in top level cmake fileGuillaume Nault
Move definition of ACCEL_PPP_VERSION from /accel-pppd/CMakeLists.txt to /CMakeLists.txt so that it gets visible by any cmake file. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2013-02-04Integrate accel-cmd with accel-ppp's build processGuillaume Nault
Create a CMakeLists.txt file for accel-cmd so that it gets compiled and installed like accel-pppd. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2013-02-04Add manpage for accel-cmdGuillaume Nault
Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2013-02-04New client for the cli module (tcp)Guillaume Nault
accel-cmd is a small program that reads commands from its command line or standard input and sends them to accel-ppp (using the tcp interface of the cli module). It displays accel-ppp's result on standard output. accel-cmd automatically appends the "exit" command to its command list, so that accel-pppd will disconnect after sending its replies. By default accel-cmd connects to localhost:2001. Examples: Send the "show sessions" command to accel-ppp and display the result: $ accel-cmd show sessions Execute commands from file "cmds" and display the results to stdout: $ accel-cmd < cmds Same as above, but use a different host and timeout after 1.5 seconds of inactivity: $ accel-cmd --timeout 1500ms --host accelppp.example.com < cmds Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2013-01-24update debian contribKozlov Dmitry
2013-01-22fix typo LIB_SIFFIX -> LIB_SUFFIXKozlov Dmitry
2013-01-11Merge branch '1.7' of ↵Kozlov Dmitry
ssh://accel-ppp.git.sourceforge.net/gitroot/accel-ppp/accel-ppp into 1.7
2013-01-11Fix boolean options parsing in configuration fileGuillaume Nault
Explicitely interpret zero values when parsing boolean options. This allows to unset boolean parameters such as "verbose" when reloading the configuration. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2012-12-26cmake: use CMAKE_FIND_ROOT_PATH and LIB_SUFFIXKozlov Dmitry
2012-12-26Revert "Pass proper pointer to rad_packet_find_attr"Kozlov Dmitry
This reverts commit d16b78813da8b69aafd13ca5086850a5d27a871e.
2012-12-26Proper logging of LCP Magic-NumbersAleksey Zhukov
2012-12-26Do not segfault on RADIUS failures during interimAleksey Zhukov
2012-12-26Pass proper pointer to rad_packet_find_attrAleksey Zhukov
2012-12-14l2tp: Fix allocation checking when adding octets AVPGuillaume Nault
l2tp_packet_add_octets() performs a malloc on the "octets" field of the L2TP attribute, but checks the "string" field for allocation failure. Though these fields should be equivalent in this case, the "octets" field should be logically checked instead of "string". Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2012-12-14cli, tcp: Fix non-NULL terminated string receptionGuillaume Nault
NULL terminate commands received in cln_read(). This ensures that the processing loop can safely call strchr(), or any other string handling functions. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2012-12-14Fix va_end() missing callsGuillaume Nault
A few va_start() calls aren't followed by their corresponding va_end(). This patch adds the missing va_end() calls. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
2012-12-071.7.3 releaseKozlov Dmitry
* fixed various bugs in cli * fixed l2tp connection problem from android * implemented chap-secrets encryption * implemented NBNS (WINS) support
2012-12-07auth_pap: make messages like other auth modulesKozlov Dmitry
2012-11-27cli: check xmit_buf is not null at enter to write functionKozlov Dmitry