Skip to content

Hemiize/Cert2Brain-Exam-Scraper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

💻 cert2brain Exam Scraper — C2B DL

grafik

Disclaimer

This tool is intended for personal study purposes only.
It automates interaction with cert2brain.com using your own valid credentials.
You are solely responsible for ensuring your use complies with cert2brain's Terms of Service.
The author provides no warranty and accepts no liability for any consequences arising from the use of this software.
A valid, active cert2brain Premium account is required.

Platform: Tested on Windows 10 / 11 only. macOS and Linux are not officially supported.


Summary

Automates downloading exam questions from cert2brain.com and generates a structured, print-ready PDF study guide.

What the tool does:

  1. Opens a Chromium browser and logs in with your credentials.
  2. Automatically fetches the question count per exam from the product page.
  3. Starts Training Mode and steps through all questions automatically.
  4. Randomly selects an answer, clicks Check, and reads the correct answer from the page.
  5. Generates a PDF (Exam_<ExamName>_<Date>.pdf) containing:
    • Title page: exam code, provider, generation date, total question count
    • One page per question
    • Question text followed immediately by the question image (if any)
    • All answer options — correct answer highlighted in green with a CORRECT tag
    • Page header (exam name) and footer (date + page number) on every page

Modes:

  • Download a single exam
  • Download all exams of a selected provider in one unattended run

Requirements

Requirement Details
cert2brain Premium Account ⚠️ Mandatory. Free accounts only get the first 10 questions.
Windows 10 / 11 Only tested platform
Python 3.10+ python.org
playwright >= 1.61.0 pip install playwright
fpdf2 >= 2.8.7 pip install fpdf2

Setup

python -m pip install -r requirements.txt
python -m playwright install chromium
python cert2brain_downloader.py

Usage

python cert2brain_downloader.py

Step by step

  1. Enter your username / e-mail (cert2brain.com account — Premium required).
  2. Enter your password — input is masked (shows * per keystroke, Backspace supported).
  3. Select a provider from the numbered list (e.g. Microsoft, CompTIA ...).
  4. Select an exam — or choose [ DOWNLOAD ALL EXAMS ] for a full provider download.
  5. The tool runs fully automatically through all questions of the selected exam.
  6. The PDF is saved in the current working directory: Exam_<Name>_<YYYY-MM-DD_HH-MM>.pdf

PDF structure

Each generated PDF contains:

Page Content
1 Title page — exam code, provider, generation date, total questions
2+ One page per question — QUESTION N header, question text, image directly below (if any), answer options A/B/C/D, CORRECT tag on the right answer

File structure

release/
├── cert2brain_downloader.py   # Main script
├── requirements.txt           # Python dependencies
└── README.md                  # This file

PDFs are saved in the directory from which the script is launched.


Notes

  • The browser opens visibly (not headless) to avoid bot detection by cert2brain.
  • On timeout, the current question is skipped and the tool continues automatically.
  • In "Download all exams" mode the run can take several hours depending on provider size.
  • Correct answers are detected by reading the color styling of answer labels after Check.
  • Question images (diagrams, screenshots) are embedded directly below the question text.

About

Simple Scraper to export Cert2Brain Exams into a PDF file

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages