Skip to content

Instantly share code, notes, and snippets.

@AndyNovo
Forked from npilla2023/AES1.md
Last active July 13, 2020 16:51
Show Gist options
  • Save AndyNovo/887fb0489a3a78762b7bd47c22e909e3 to your computer and use it in GitHub Desktop.
Save AndyNovo/887fb0489a3a78762b7bd47c22e909e3 to your computer and use it in GitHub Desktop.

Level 1: Finding a Shared Key

Thanks to Diffie-Hellman Key Exchange, the STARS can share secret messages that the CRABS will never crack. The STARS want to ensure that you can properly execute this process, so this is your chance to prove yourself as a promising agent. Agent Ocean will be training you.

Here is the information you have been briefed with:
Your super secret value is: 109306739515372000536684615587060142161
Agent Ocean's public value is: 54224788903180805177809934100426766384

Complete the following steps in order to find your shared secret phrase with Agent Ocean before you can start sending secret messages. And yes, we will be using the terminal and python for this mission.

  1. Open up the TERMINAL in a new tab (click start).
  2. Type the following commands into the terminal to prepare the script that you will need to use:
    wget https://prof.ninja/dhe.sh
    chmod +x dhe.sh
  3. Now type this command into the terminal, substituting your super secret value for <your_secret> and Agent Ocean's public value for <their_public>:
    ./dhe.sh <your_secret> <their_public>
  4. The returned number is your shared secret phrase with Agent Ocean.
  5. Store the shared secret phrase because you will need to use it later.

What is your shared secret phrase with Agent Ocean?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment