summaryrefslogtreecommitdiff
path: root/pppd/magic.h
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2003-06-11 23:56:26 +0000
committerPaul Mackerras <paulus@samba.org>2003-06-11 23:56:26 +0000
commit71d3de90eae52087b405e962ca650b71cec79c67 (patch)
tree72920173c399582b3b069cb80255aed0040d4d45 /pppd/magic.h
parent14b5af09f0a70c5f6e6a3d2de11e578616a2ac85 (diff)
downloadppp-71d3de90eae52087b405e962ca650b71cec79c67.tar.gz
New CHAP implementation, rewritten from scratch to avoid the code
copyrighted by the uncontactable Gregory Christy. The new code is much cleaner and splits out all the digest-specific code to separate files. Thus the CHAP-MD5 stuff is now in chap-md5.c and all the CHAP-MS and CHAP-MSv2 stuff has moved into chap_ms.c, instead of having half of it in chap.c. There are a few minor differences in this implementation; we don't retransmit responses, but instead just wait for a new challenge. The success/failure messages are more boring as well. In fact the digest code now sets the success/failure message. CHAP_DIGEST_MD5 has been renamed to CHAP_MD5 for consistency. There is a new function random_bytes() in magic.c, which generates a string of random bytes.
Diffstat (limited to 'pppd/magic.h')
-rw-r--r--pppd/magic.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/pppd/magic.h b/pppd/magic.h
index 38718fb..c81213b 100644
--- a/pppd/magic.h
+++ b/pppd/magic.h
@@ -39,8 +39,11 @@
* AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
* OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $Id: magic.h,v 1.4 2002/12/04 23:03:32 paulus Exp $
+ * $Id: magic.h,v 1.5 2003/06/11 23:56:26 paulus Exp $
*/
void magic_init __P((void)); /* Initialize the magic number generator */
u_int32_t magic __P((void)); /* Returns the next magic number */
+
+/* Fill buffer with random bytes */
+void random_bytes __P((unsigned char *buf, int len));