/* POINTER defines a generic pointer type */
typedef unsigned char *POINTER;
+#define _POINTER_T
/* UINT2 defines a two byte word */
typedef unsigned short int UINT2;
+#define _UINT2_T
/* UINT4 defines a four byte word */
#if defined(__alpha) && (defined(__osf__) || defined(__linux__))
#else
typedef unsigned long int UINT4;
#endif
+#define _UINT4_T
/* PROTO_LIST is defined depending on how PROTOTYPES is defined above.
If using PROTOTYPES, then PROTO_LIST returns the list, otherwise it
#endif
/* POINTER defines a generic pointer type */
+#ifndef _POINTER_T
typedef unsigned char *POINTER;
+#endif
typedef const unsigned char *CONSTPOINTER;
/* UINT2 defines a two byte word */
+#ifndef _UINT2_T
typedef unsigned short int UINT2;
+#endif
/* UINT4 defines a four byte word */
+#ifndef _UINT4_T
#if defined(__alpha) && (defined(__osf__) || defined(__linux__))
typedef unsigned int UINT4;
#else
typedef unsigned long int UINT4;
#endif
+#endif
/* PROTO_LIST is defined depending on how PROTOTYPES is defined above.
If using PROTOTYPES, then PROTO_LIST returns the list, otherwise it
include ../../Make.inc
OBJS = dict.o print.o radius.o valuepair.o token.o misc.o \
- log.o filters.o missing.o md5.o hmac.o snprintf.o
+ log.o filters.o missing.o md4.o md5.o sha1.o hmac.o snprintf.o
INCLUDES = ../include/radius.h ../include/libradius.h \
../include/missing.h ../include/autoconf.h
missing.o: missing.c $(INCLUDES)
$(CC) $(CFLAGS) -c missing.c
+md4.o: md4.c ../include/md4.h
+ $(CC) $(CFLAGS) -c md4.c
+
md5.o: md5.c ../include/md5.h
$(CC) $(CFLAGS) -c md5.c
+sha1.o: sha1.c ../include/sha1.h
+ $(CC) $(CFLAGS) -c sha1.c
+
hmac.o: hmac.c $(INCLUDES)
$(CC) $(CFLAGS) -c hmac.c
TARGET = rlm_mschap
-SRCS = rlm_mschap.c deskey.c desport.c md4c.c smbpass.c sha1.c
-HEADERS = md4.h des.h smbpass.h sha1.h
+SRCS = rlm_mschap.c deskey.c desport.c smbpass.c
+HEADERS = des.h smbpass.h
RLM_CFLAGS =
RLM_UTILS = smbencrypt
RLM_INSTALL = smbencrypt
$(DYNAMIC_OBJS): $(HEADERS)
smbencrypt: $(STATIC_OBJS)
- $(CC) $(LDFLAGS) -osmbencrypt smbencrypt.c deskey.o desport.o md4c.o smbpass.o
\ No newline at end of file
+ $(CC) -I../../include $(LDFLAGS) -o smbencrypt smbencrypt.c deskey.o desport.o smbpass.o ../../lib/md4.o
+ LM support to MS-CHAP
+ support for SAMBA passwd files. It introduces new files smbpass.c and
smbpass.h
-+ support for MS-CHAPv2. SHA1 digest support was added (sha1.c, sha2.c)
++ support for MS-CHAPv2. SHA1 digest support was added (sha1.c, sha1.h)
! module is configurable via radiusd.conf and supports instances
! module supports both authorization and authentication. Authorization
sets authentication to MS-CHAP if any NTLM-related things found.
#include "modules.h"
#include "des.h"
+#include "md4.h"
#include "md5.h"
#include "sha1.h"
#include "smbpass.h"
uint8_t* salt,uint8_t* enckey,uint8_t* key);
#endif
-void md4_calc (unsigned char *, unsigned char *, unsigned int);
-
/*
*/
-#include "../../include/autoconf.h"
-#include "../../include/libradius.h"
+#include "autoconf.h"
+#include "libradius.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>