Deleted Added
full compact
radius.c (51517) radius.c (54914)
1/*
2 * Copyright 1999 Internet Business Solutions Ltd., Switzerland
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 9 unchanged lines hidden (view full) ---

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
1/*
2 * Copyright 1999 Internet Business Solutions Ltd., Switzerland
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 9 unchanged lines hidden (view full) ---

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
26 * $FreeBSD: head/usr.sbin/ppp/radius.c 51517 1999-09-21 19:37:00Z brian $
26 * $FreeBSD: head/usr.sbin/ppp/radius.c 54914 1999-12-20 20:30:02Z brian $
27 *
28 */
29
30#include <sys/param.h>
31#include <netinet/in_systm.h>
32#include <netinet/in.h>
33#include <netinet/ip.h>
34#include <arpa/inet.h>

--- 136 unchanged lines hidden (view full) ---

171 return;
172 }
173
174 log_Printf(LogPHASE, " Route: %s\n", nuke);
175 bundle = r->cx.auth->physical->dl->bundle;
176 dest.ipaddr.s_addr = dest.mask.s_addr = INADDR_ANY;
177 dest.width = 0;
178 argc = command_Interpret(nuke, strlen(nuke), argv);
27 *
28 */
29
30#include <sys/param.h>
31#include <netinet/in_systm.h>
32#include <netinet/in.h>
33#include <netinet/ip.h>
34#include <arpa/inet.h>

--- 136 unchanged lines hidden (view full) ---

171 return;
172 }
173
174 log_Printf(LogPHASE, " Route: %s\n", nuke);
175 bundle = r->cx.auth->physical->dl->bundle;
176 dest.ipaddr.s_addr = dest.mask.s_addr = INADDR_ANY;
177 dest.width = 0;
178 argc = command_Interpret(nuke, strlen(nuke), argv);
179 if (argc < 2)
179 if (argc < 0)
180 log_Printf(LogWARN, "radius: %s: Syntax error\n",
181 argc == 1 ? argv[0] : "\"\"");
182 else if (argc < 2)
180 log_Printf(LogWARN, "radius: %s: Invalid route\n",
181 argc == 1 ? argv[0] : "\"\"");
182 else if ((strcasecmp(argv[0], "default") != 0 &&
183 !ParseAddr(&bundle->ncp.ipcp, argv[0], &dest.ipaddr,
184 &dest.mask, &dest.width)) ||
185 !ParseAddr(&bundle->ncp.ipcp, argv[1], &gw, NULL, NULL))
186 log_Printf(LogWARN, "radius: %s %s: Invalid route\n",
187 argv[0], argv[1]);

--- 283 unchanged lines hidden ---
183 log_Printf(LogWARN, "radius: %s: Invalid route\n",
184 argc == 1 ? argv[0] : "\"\"");
185 else if ((strcasecmp(argv[0], "default") != 0 &&
186 !ParseAddr(&bundle->ncp.ipcp, argv[0], &dest.ipaddr,
187 &dest.mask, &dest.width)) ||
188 !ParseAddr(&bundle->ncp.ipcp, argv[1], &gw, NULL, NULL))
189 log_Printf(LogWARN, "radius: %s %s: Invalid route\n",
190 argv[0], argv[1]);

--- 283 unchanged lines hidden ---