Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > General Coding > Coding Tutorials
You last visited: Today at 13:42

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Send Commands - iBoot/iBSS

Discussion on Send Commands - iBoot/iBSS within the Coding Tutorials forum part of the General Coding category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Sep 2013
Posts: 211
Received Thanks: 36
Arrow Send Commands - iBoot/iBSS

Hey, heute mal ein kleines "Tutorial" wie ihr Kommandos an iOS Geräten im Recovery Mode sendet.
Da das ganze iBoot(iBec image - iBSS) ist, hat es ein interaktives Interface was per serial oder USB angesprochen werden kann.
Wir senden keine Datein oder rufen den Status ab, nein wie senden einfach mal Kommandos.
Wir arbeiten heute mit LibUSB (C) und PYUSB(Python) damit C und Python Entwickler etwas davon haben.
Es ist aber sehr einfach das ganze in vb.net, c++, c# etc zu porten da man nur die Funtkion wissen muss.

Hiermit senden wir ein Kommando:
PHP Code:
usb_control_msg(device_handle0x40000bufstrlen(buf), 1000); 
Das ganze würde dann in LIBUSB C Code so aussehen:
PHP Code:
libusb_control_transfer(device_handle0x40000command[0], (strlen(command[0]) + 1), 1000
Erstmal aber wie wir device_handle richtig konfigurieren:
PHP Code:
struct libusb_device_handle *handle;
handle libusb_open_device_with_vid_pid(NULL0x05AC0x1281); 
Davor dann halt noch das bekannte libusb_init setzen:
PHP Code:
libusb_init(NULL); 
VID und PID für die Kontrolle des Recovery Modes:
PHP Code:
0x05AC0x1281 
Wen wir dann am Ende alles mal zusammen fassen um ein Kommando zu senden, dann könnte das so aussehen:
PHP Code:
#include <stdlib.h>
#include <stdio.h>
#include <libusb-1.0/libusb.h>
#include <usb.h>

int cmd();
struct libusb_device_handle *device_handle;

int main() {
    
libusb_init(NULL);
    
device_handle libusb_open_device_with_vid_pid(NULL0x05AC0x1281);
    
libusb_control_transfer(device_handle0x40000"reboot", (strlen("reboot") + 1), 1000);
    return 
1;

Mit einer Abfrage ob das ganze erfolgreich oder nicht war sieht der Code so aus:
PHP Code:
#include <stdlib.h>
#include <stdio.h>
#include <libusb-1.0/libusb.h>
#include <usb.h>

int cmd();
struct libusb_device_handle *device_handle;

int main() {
    
libusb_init(NULL);
    
device_handle libusb_open_device_with_vid_pid(NULL0x05AC0x1281);
    if (
libusb_control_transfer(device_handle0x40000"reboot", (strlen("reboot") + 1), 1000)) {
        
printf("[*] Successfully sent command.\r\n");
        return 
0;
    } else {
        
printf("[*] Error with sending the Command");
        return 
0;
    }
    return 
1;


Mit gcc könnt ihr dass z.b. für Mac so kompilieren:
PHP Code:
cal0x:~ cal0xgcc -o send_cmd send_cmd.-lusb-1.0 -framework IOKit 
In Python ein Send Command Beispiel:
PHP Code:
import usb.core
import usb
.util
import sys

dev 
usb.core.find(idVendor=0x05ACidProduct=0x1281)
cmd "reboot" # Add any command here.
ret dev.ctrl_transfer(0x40000cmd1000
Mit einer Abfrage ob ein Gerät verbunden ist, auch noch mal:
PHP Code:
import usb.core
import usb
.util
import sys

dev 
usb.core.find(idVendor=0x05ACidProduct=0x1281)
if (
dev):
    print 
'Device in recovery Mode connected.'
    
cmd "reboot" # Add any command here.
    
ret dev.ctrl_transfer(0x40000cmd1000)

else:
    print 
'No device in recovery mode found.' 
Ein Utility in C ist selbstverständlich auch verfügbar.
Es heißt OpeniSenc_rec und ist im OpenSun-C Paket oder alleine verfügbar:



Das Python Beispiel ist auch auf meinem Github Account verfügbar:


P.S: Ein Thx tut keinem weh . Aber wayne .
iOSsec is offline  
Reply


Similar Threads Similar Threads
VB.NET - Pointers and send key commands to DX9 game
05/26/2013 - .NET Languages - 4 Replies
Ant one that knows how to read pointers/memory from a online game ? like hp/mana/exp and get them in the program ? Also any ideas to send key commands to an game that is coded with DX9 apis ?
[HOWTO] Send commands to server on INT
06/19/2011 - Kal Online - 4 Replies
To send commands to the server you must: 1. Get your code into the kal process. Use an injector, or use the recently popular dsound.dll > bot.dll technique (what would we technically call this???). 2. Find the send function address. Plenty of public code for this around, but let's use this common source (if you originally wrote this code, claim it because I don't know). DWORD Send_To_Server_Main_ = SearchPattern("55 8B EC 83 EC 18 83 3D x x x x 00 74 07 33 C0 E9 x x x x 8A 45...
how to ban/send to bot jail with gm commands
07/13/2010 - CO2 Private Server - 4 Replies
guys, i have a co pserver5165 can some one tell me how to ban or send to bot jail with gm commands?
Can someone send me v5017 commands through msn messenger?
08/24/2009 - CO2 Private Server - 1 Replies
Send me commands. Add me [email protected]



All times are GMT +2. The time now is 13:42.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.