mirror of
https://github.com/unrealircd/unrealircd.git
synced 2026-07-06 14:13:12 +02:00
Yeah yeah, blah blah shit
This commit is contained in:
@@ -1166,3 +1166,5 @@ v- Fixed some bugreport stuff
|
||||
(suggested by dimplesx #0000058
|
||||
- Made the win32 version set log files to writable if they are
|
||||
read only (reported by dimplesx #0000057)
|
||||
- Removed useless stuff in m_oper (null ptr thing, just dont set them)
|
||||
- Fixed auth.c to use random salt
|
||||
|
||||
+2
-7
@@ -176,10 +176,7 @@ int Auth_Check(aClient *cptr, anAuthStruct *as, char *para)
|
||||
/* If our data is like 1 or none, we just let em through .. */
|
||||
if (!(as->data[0] && as->data[1]))
|
||||
return 1;
|
||||
salt[0] = as->data[0];
|
||||
salt[1] = as->data[1];
|
||||
salt[2] = '\0';
|
||||
if (!strcmp(crypt(para, salt), as->data))
|
||||
if (!strcmp(crypt(para, as->data), as->data))
|
||||
return 2;
|
||||
else
|
||||
return -1;
|
||||
@@ -292,9 +289,7 @@ char *Auth_Make(short type, char *para)
|
||||
/* If our data is like 1 or none, we just let em through .. */
|
||||
if (!(para[0] && para[1]))
|
||||
return NULL;
|
||||
salt[0] = para[0];
|
||||
salt[1] = para[1];
|
||||
salt[2] = '\0';
|
||||
sprintf(salt, "%02X", (rand() >> 24) & 0xFF);
|
||||
return(crypt(para, salt));
|
||||
break;
|
||||
#endif
|
||||
|
||||
@@ -255,7 +255,7 @@ DLLFUNC int m_oper(aClient *cptr, aClient *sptr, int parc, char *parv[]) {
|
||||
sptr->oflag = aconf->oflags;
|
||||
|
||||
if ((aconf->oflags & OFLAG_HIDE) && iNAH && !BadPtr(host)) {
|
||||
iNAH_host(sptr, (host != NULL) ? host : "eek.host.is.null.pointer");
|
||||
iNAH_host(sptr, host);
|
||||
}
|
||||
|
||||
if (announce != NULL) {
|
||||
|
||||
Reference in New Issue
Block a user