Netservices modded to read fragmented HTTP respsonse/payload from special purpose server - 180 bytes only

Committer:
RodColeman
Date:
Thu Sep 08 10:41:36 2011 +0000
Revision:
0:8f5825f330b0
setDataLen hacked to 180bytes

Who changed what in which revision?

UserRevisionLine numberNew contents of line
RodColeman 0:8f5825f330b0 1 /*****************************************************************************
RodColeman 0:8f5825f330b0 2 * auth.h - PPP Authentication and phase control header file.
RodColeman 0:8f5825f330b0 3 *
RodColeman 0:8f5825f330b0 4 * Copyright (c) 2003 by Marc Boucher, Services Informatiques (MBSI) inc.
RodColeman 0:8f5825f330b0 5 * portions Copyright (c) 1998 Global Election Systems Inc.
RodColeman 0:8f5825f330b0 6 *
RodColeman 0:8f5825f330b0 7 * The authors hereby grant permission to use, copy, modify, distribute,
RodColeman 0:8f5825f330b0 8 * and license this software and its documentation for any purpose, provided
RodColeman 0:8f5825f330b0 9 * that existing copyright notices are retained in all copies and that this
RodColeman 0:8f5825f330b0 10 * notice and the following disclaimer are included verbatim in any
RodColeman 0:8f5825f330b0 11 * distributions. No written agreement, license, or royalty fee is required
RodColeman 0:8f5825f330b0 12 * for any of the authorized uses.
RodColeman 0:8f5825f330b0 13 *
RodColeman 0:8f5825f330b0 14 * THIS SOFTWARE IS PROVIDED BY THE CONTRIBUTORS *AS IS* AND ANY EXPRESS OR
RodColeman 0:8f5825f330b0 15 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
RodColeman 0:8f5825f330b0 16 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
RodColeman 0:8f5825f330b0 17 * IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
RodColeman 0:8f5825f330b0 18 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
RodColeman 0:8f5825f330b0 19 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
RodColeman 0:8f5825f330b0 20 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
RodColeman 0:8f5825f330b0 21 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
RodColeman 0:8f5825f330b0 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
RodColeman 0:8f5825f330b0 23 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
RodColeman 0:8f5825f330b0 24 *
RodColeman 0:8f5825f330b0 25 ******************************************************************************
RodColeman 0:8f5825f330b0 26 * REVISION HISTORY
RodColeman 0:8f5825f330b0 27 *
RodColeman 0:8f5825f330b0 28 * 03-01-01 Marc Boucher <marc@mbsi.ca>
RodColeman 0:8f5825f330b0 29 * Ported to lwIP.
RodColeman 0:8f5825f330b0 30 * 97-12-04 Guy Lancaster <lancasterg@acm.org>, Global Election Systems Inc.
RodColeman 0:8f5825f330b0 31 * Original derived from BSD pppd.h.
RodColeman 0:8f5825f330b0 32 *****************************************************************************/
RodColeman 0:8f5825f330b0 33 /*
RodColeman 0:8f5825f330b0 34 * pppd.h - PPP daemon global declarations.
RodColeman 0:8f5825f330b0 35 *
RodColeman 0:8f5825f330b0 36 * Copyright (c) 1989 Carnegie Mellon University.
RodColeman 0:8f5825f330b0 37 * All rights reserved.
RodColeman 0:8f5825f330b0 38 *
RodColeman 0:8f5825f330b0 39 * Redistribution and use in source and binary forms are permitted
RodColeman 0:8f5825f330b0 40 * provided that the above copyright notice and this paragraph are
RodColeman 0:8f5825f330b0 41 * duplicated in all such forms and that any documentation,
RodColeman 0:8f5825f330b0 42 * advertising materials, and other materials related to such
RodColeman 0:8f5825f330b0 43 * distribution and use acknowledge that the software was developed
RodColeman 0:8f5825f330b0 44 * by Carnegie Mellon University. The name of the
RodColeman 0:8f5825f330b0 45 * University may not be used to endorse or promote products derived
RodColeman 0:8f5825f330b0 46 * from this software without specific prior written permission.
RodColeman 0:8f5825f330b0 47 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
RodColeman 0:8f5825f330b0 48 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
RodColeman 0:8f5825f330b0 49 * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
RodColeman 0:8f5825f330b0 50 *
RodColeman 0:8f5825f330b0 51 */
RodColeman 0:8f5825f330b0 52
RodColeman 0:8f5825f330b0 53 #ifndef AUTH_H
RodColeman 0:8f5825f330b0 54 #define AUTH_H
RodColeman 0:8f5825f330b0 55
RodColeman 0:8f5825f330b0 56 /***********************
RodColeman 0:8f5825f330b0 57 *** PUBLIC FUNCTIONS ***
RodColeman 0:8f5825f330b0 58 ***********************/
RodColeman 0:8f5825f330b0 59
RodColeman 0:8f5825f330b0 60 /* we are starting to use the link */
RodColeman 0:8f5825f330b0 61 void link_required (int);
RodColeman 0:8f5825f330b0 62
RodColeman 0:8f5825f330b0 63 /* we are finished with the link */
RodColeman 0:8f5825f330b0 64 void link_terminated (int);
RodColeman 0:8f5825f330b0 65
RodColeman 0:8f5825f330b0 66 /* the LCP layer has left the Opened state */
RodColeman 0:8f5825f330b0 67 void link_down (int);
RodColeman 0:8f5825f330b0 68
RodColeman 0:8f5825f330b0 69 /* the link is up; authenticate now */
RodColeman 0:8f5825f330b0 70 void link_established (int);
RodColeman 0:8f5825f330b0 71
RodColeman 0:8f5825f330b0 72 /* a network protocol has come up */
RodColeman 0:8f5825f330b0 73 void np_up (int, u16_t);
RodColeman 0:8f5825f330b0 74
RodColeman 0:8f5825f330b0 75 /* a network protocol has gone down */
RodColeman 0:8f5825f330b0 76 void np_down (int, u16_t);
RodColeman 0:8f5825f330b0 77
RodColeman 0:8f5825f330b0 78 /* a network protocol no longer needs link */
RodColeman 0:8f5825f330b0 79 void np_finished (int, u16_t);
RodColeman 0:8f5825f330b0 80
RodColeman 0:8f5825f330b0 81 /* peer failed to authenticate itself */
RodColeman 0:8f5825f330b0 82 void auth_peer_fail (int, u16_t);
RodColeman 0:8f5825f330b0 83
RodColeman 0:8f5825f330b0 84 /* peer successfully authenticated itself */
RodColeman 0:8f5825f330b0 85 void auth_peer_success (int, u16_t, char *, int);
RodColeman 0:8f5825f330b0 86
RodColeman 0:8f5825f330b0 87 /* we failed to authenticate ourselves */
RodColeman 0:8f5825f330b0 88 void auth_withpeer_fail (int, u16_t);
RodColeman 0:8f5825f330b0 89
RodColeman 0:8f5825f330b0 90 /* we successfully authenticated ourselves */
RodColeman 0:8f5825f330b0 91 void auth_withpeer_success (int, u16_t);
RodColeman 0:8f5825f330b0 92
RodColeman 0:8f5825f330b0 93 /* check authentication options supplied */
RodColeman 0:8f5825f330b0 94 void auth_check_options (void);
RodColeman 0:8f5825f330b0 95
RodColeman 0:8f5825f330b0 96 /* check what secrets we have */
RodColeman 0:8f5825f330b0 97 void auth_reset (int);
RodColeman 0:8f5825f330b0 98
RodColeman 0:8f5825f330b0 99 /* Check peer-supplied username/password */
RodColeman 0:8f5825f330b0 100 u_char check_passwd (int, char *, int, char *, int, char **, int *);
RodColeman 0:8f5825f330b0 101
RodColeman 0:8f5825f330b0 102 /* get "secret" for chap */
RodColeman 0:8f5825f330b0 103 int get_secret (int, char *, char *, char *, int *, int);
RodColeman 0:8f5825f330b0 104
RodColeman 0:8f5825f330b0 105 /* check if IP address is authorized */
RodColeman 0:8f5825f330b0 106 int auth_ip_addr (int, u32_t);
RodColeman 0:8f5825f330b0 107
RodColeman 0:8f5825f330b0 108 /* check if IP address is unreasonable */
RodColeman 0:8f5825f330b0 109 int bad_ip_adrs (u32_t);
RodColeman 0:8f5825f330b0 110
RodColeman 0:8f5825f330b0 111 #endif /* AUTH_H */