Sitemap

TryHackMe | Security Engineer (introduction to Security Engineering) — Write-up

10 min readSep 29, 2023

--

In this article I will answer all the 5 Rooms in the new learning path provided by tryhackme in five articles and With a full explanation of the steps, so don’t forget to make a follow to know the other Rooms answers and why.

This is the Link: (Security Engineer)

Credited: TryHackMe (Security Engineer Intro)

First Room is Security Engineer Intro

Answer the questions below:
Who ensures that an organization’s cyber security risk is minimized at all times?
ANS: Security Engineer

Where are details about an organization’s digital assets, such as name, IP address, and owner, stored?

Press enter or click to view image in full size
ANS: Asset Inventory

Sometimes security policies can’t be followed because of business needs. What avenue does a security engineer have to fulfil business needs in these cases?

Press enter or click to view image in full size
ANS: exceptions

What philosophy, if followed, provides the most Return on Investment (ROI)?

Press enter or click to view image in full size
ANS: secure by design

What is considered the weakest link in an organization’s security?

ANS: Humans

An organization’s security evolves with the organization. What helps a security engineer keep the organization secure through these changes?

Press enter or click to view image in full size
ANS: Change Management

What is a theoretical exercise carried out to gauge the operational readiness of an organization from a security point of view?

Press enter or click to view image in full size
ANS: Tabletop Exercises

What is the priority of the management in case of a disaster or crisis?

Press enter or click to view image in full size
ANS: business continuity

What is the flag shown on the completion of the static site?

first answer
the same

THM{S3CUR1TY_3NG1N33R5_R0CK}

Security Principles

Click on “View Site” and answer the five questions. What is the flag that you obtained at the end?
ANS: THM{CIA_TRIAD}

The attacker managed to gain access to customer records and dumped them online. What is this attack?
ANS: Disclosure

A group of attackers were able to locate both the main and the backup power supply systems and switch them off. As a result, the whole network was shut down. What is this attack?
ANS: Destruction/Denial

Click on “View Site” and answer the four questions. What is the flag that you obtained at the end?
ANS: THM{SECURITY_MODELS}

Which principle are you applying when you turn off an insecure server that is not critical to the business?

Press enter or click to view image in full size
ANS: 2

Your company hired a new sales representative. Which principle are they applying when they tell you to give them access only to the company products and prices?

Press enter or click to view image in full size
ANS: 1

While reading the code of an ATM, you noticed a huge chunk of code to handle unexpected situations such as network disconnection and power failure. Which principle are they applying?
ANS: 5

Introduction to Cryptography

Press enter or click to view image in full size
Credited: tryhackme (Introduction to Cryptography)

You have received the following encrypted message:
“Xjnvw lc sluxjmw jsqm wjpmcqbg jg wqcxqmnvw; xjzjmmjd lc wjpm sluxjmw jsqm bqccqm zqy.” Zlwvzjxj Zpcvcol
You can guess that it is a quote. Who said it?

Press enter or click to view image in full size
First we open the tool was give us

then write the encrypted message to decrypt it.

Press enter or click to view image in full size
ANS: Miyamoto Musashi

Decrypt the file quote01 encrypted (using AES256) with the key s!kR3T55 using gpg. What is the third word in the file?
First we will go to the directory using the below command as in the Room.
cd /root/Rooms/cryptographyintro/task02
then using the ls command to know the files names we have to work with

in this photo i used cd & ls

the we write the commend we need to crack the file “quote01.txt.gpg”
gpg — output original_message.txt — decrypt quote01.txt.gpg
a pop up window show up and we will write the Key that the room provided s!kR3T55
Then we file will be created with the answer we need after the file have been plaintext
ANS: waste

Decrypt the file quote02 encrypted (using AES256-CBC) with the key s!kR3T55 using openssl. What is the third word in the file?

we will write the next command and then it will ask for the Key
openssl aes-256-cbc -d -in quote02 -out original_message.txt

now write the key and you will see the answer

ANS: science

Decrypt the file quote03 encrypted (using CAMELLIA256) with the key s!kR3T55 using gpg. What is the third word in the file?

the same in the first question we will use the same commands

Press enter or click to view image in full size

ANS: understand
On the AttackBox, you can find the directory for this task located at /root/Rooms/cryptographyintro/task03; alternatively, you can use the task file from Task 2 to work on your own machine.

Bob has received the file ciphertext_message sent to him from Alice. You can find the key you need in the same folder. What is the first word of the original plaintext?

First we will go to the directory using the below command as in the Room.
cd /root/Rooms/cryptographyintro/task03

then write the below command to decrept

openssl pkeyutl -decrypt -in ciphertext_message -inkey private-key-bob.pem -out decrypted.txt

then write (cat decrypted.txt) to find the answer.

ANS: Perception

Take a look at Bob’s private RSA key. What is the last byte of p?

the p is the output of prime1

so by write this command we will have the answer
openssl rsa -in private-key-bob.pem -text -noout

ANS: e7

Take a look at Bob’s private RSA key. What is the last byte of q?

the same as before but it will be the prime2

ANS: 27

On the AttackBox, you can find the directory for this task located at /root/Rooms/cryptographyintro/task04; alternatively, you can use the task file from Task 2 to work on your own machine.

A set of Diffie-Hellman parameters can be found in the file dhparam.pem. What is the size of the prime number in bits?

First we will go to the directory using the below command as in the Room.
cd /root/Rooms/cryptographyintro/task04

then write the below command to find the answer

openssl dhparam -in dhparams.pem -text -noout

ANS: 4096

What is the prime number’s last byte (least significant byte)?

ANS: 4f

Get 0x0Aleem’s stories in your inbox

Join Medium for free to get updates from this writer.

On the AttackBox, you can find the directory for this task located at /root/Rooms/cryptographyintro/task05; alternatively, you can use the task file from Task 2 to work on your own machine.

What is the SHA256 checksum of the file order.json?

after moving to the directory using the cd command we will use the below to make the checksum

sha256sum order.json

and the answer will be
ANS: 2c34b68669427d15f76a1c06ab941e3e6038dacdfb9209455c87519a3ef2c660

Open the file order.json and change the amount from 1000 to 9000. What is the new SHA256 checksum?
we will use nano editor to view and edite the file
nano order.json

we will make the change and then save it (CTRL+X)

we will check again and will find different hash value
sha256sum order.json

ANS :11faeec5edc2a2bad82ab116bbe4df0f4bc6edd96adac7150bb4e6364a238466
Using SHA256 and the key 3RfDFz82, what is the HMAC of order.txt?

after trying different commands to answer this, The only command that worked in the machine is
hmac256 3RfDFz82 order.txt
ANS: c7e4de386a09ef970300243a70a444ee2a4ca62413aeaeb7097d43d2c5fac89f
On the AttackBox, you can find the directory for this task located at /root/Rooms/cryptographyintro/task06; alternatively, you can use the task file from Task 2 to work on your own machine.

What is the size of the public key in bits?

after moveing to the directory cd /root/Rooms/cryptographyintro/task06
use this command to answer openssl x509 -in cert.pem -text

Press enter or click to view image in full size

ANS: 4096

Till which year is this certificate valid?

Press enter or click to view image in full size

ANS: 2039

You were auditing a system when you discovered that the MD5 hash of the admin password is 3fc0a7acf087f549ac2b266baf94b8b1. What is the original password?

we will use online MD5 crack tool like below (https://md5decrypt.net/en/)

Press enter or click to view image in full size

ANS: qwerty123

Identity and Access Management

Credited: TryHackMe (Identity and Access Management)

What is the name of the room recommended to finish before this one?

ANS: Security Principles

You are granted access to read and send an email. What is the name of this process?

ANS: Authorisation

Which process would require you to enter your username?

ANS: Identification

Although you have write access, you should only make changes if necessary for the task. Which process is required to enforce this policy?

ANS: Accountability

Which of the following cannot be used for identification?

  1. Email address
  2. Mobile number with international code
  3. Year of birth
  4. Passport number

ANS: 3

Which of the following cannot be used for identification?

  1. Landline phone number
  2. Street number
  3. Health insurance card number
  4. Student ID number

ANS: 2

When you want to check your email, you enter your username and password. What kind of authentication is your email provider using?

ANS: 1

Your bank lets you finish most of your banking operations using its app. You can log in to your banking app by providing a username and a password and then entering the code received via SMS. What kind of authentication is the banking app using?

ANS: 4

Your new landline phone system at home allows callers to leave you a message when the call is not picked up. You can call your home number and enter a secret number to listen to recorded messages. What kind of authentication is being used here?

ANS: 1

You have just started working at an advanced research centre. You learned that you need to swipe your card and enter a four-digit PIN whenever you want to use the elevator. Under which group does this authentication fall?

ANS: 4

The new policy states that the secretary should be able to send an email on the manager’s behalf. What is this policy dictating?

ANS: 1

You shared a document with your colleague and gave them view permissions so they could read without making changes. What would ensure that your file won’t be modified?

ANS: 2

The hotel management decided that the cleaning staff needed access to all the hotel rooms to do their work. What phase is this decision part of?

ANS: 1

What does IdM stand for?

ANS: Identity Management

What does IAM stand for?

ANS: Identity and Access Management

The attacker could authenticate using the user’s response when the authentication protocol required a password encrypted with a shared key. What is the name of the attack?

ANS: replay attack

You are sharing a document via a network share and giving edit permission only to the accounting department. What example of access control is this?

ANS: 2

You published a post on a social media platform and made it only visible to three out of your two hundred friends. What kind of access control did you use?

ANS: 1

What does SSO stand for?

ANS: Single Sign-On

Does SSO simplify MFA use as it needs to be set up once? (Yea/Nay)

ANS: Yea

Is it true that SSO can be cumbersome as it requires the user to remember and input different passwords for the various services? (Yea/Nay)

ANS: Nay

Does SSO allow users to access various services after signing in once? (Yea/Nay)

ANS: Yea

Does the user need to create and remember a single password when using SSO? (Yea/Nay)

ANS: Yea

It is worth repeating that we need to have proper processes in place to help protect the security of the data, systems, and networks. Expressing this in technical terms, protecting the security of a system, for example, means protecting the confidentiality, integrity, and availability of that system. And part of the proper processes required includes appropriate identification, authentication, authorisation, access control, accountability, and logging, among others. Inadequacy in any one process results in the weakening of the security of the respective systems. Securing one process won’t replace securing the other processes.
“actually it was a very nice challenge”

ANS: {THM_ACCESS_CONTROL}

I will answer all the rooms soon enough..

--

--