typedef struct Passwordreq Passwordreq;
typedef struct OChapreply OChapreply;
typedef struct OMSchapreply OMSchapreply;
+typedef struct NTLMreply NTLMreply;
typedef struct Authkey Authkey;
NETCHLEN= 16, /* max network challenge length (used in AS protocol) */
CONFIGLEN= 14,
SECRETLEN= 32, /* secret max size */
+ PASSWDLEN= 28, /* password max size */
NONCELEN= 32,
AuthHttp=13, /* http domain login */
AuthVNC=14, /* VNC server login (deprecated) */
AuthPAK=19, /* authenticated diffie hellman key agreement */
+ AuthMSchapv2=21,/* MS chap v2 authentication for ppp */
+ AuthNTLM=22, /* NTLM authentication for cifs */
AuthTs=64, /* ticket encrypted with server's key */
AuthTc, /* ticket encrypted with client's key */
AuthAs, /* server generated authenticator */
struct Passwordreq
{
char num;
- char old[ANAMELEN];
- char new[ANAMELEN];
+ char old[PASSWDLEN];
+ char new[PASSWDLEN];
char changesecret;
char secret[SECRETLEN]; /* new secret */
};
-#define MAXPASSREQLEN (12+2*ANAMELEN+1+SECRETLEN+16)
+#define MAXPASSREQLEN (12+2*PASSWDLEN+1+SECRETLEN+16)
struct OChapreply
{
};
#define OMSCHAPREPLYLEN (ANAMELEN+24+24)
+struct NTLMreply
+{
+ uchar len[2]; /* size of structure (lsb first) */
+ char uid[ANAMELEN];
+ char dom[DOMLEN];
+ char LMresp[24]; /* Lan Manager response */
+ char NTresp[24]; /* NT response (variable length) */
+};
+#define NTLMREPLYLEN (2+ANAMELEN+DOMLEN+24+24)
+
struct Authkey
{
char des[DESKEYLEN]; /* DES key from password */
extern uchar nvcsum(void*, int);
extern int readnvram(Nvrsafe*, int);
+extern char* readcons(char*, char*, int);
/*
* call up auth server