Description
In order to become familiar with the virtual machine and its assembly language, you have to write an assembly code that performs a comparison.
The machine is initialized with two random values in the registers R5
and R6
.
At the end of the program, R0
must contain 1
if the values are different, 0
otherwise.
The bytecode will be sent in hexadecimal format, which can be generated using the provided assembler (assembly.py
file).
The documentation of the virtual machine is available on this page.
Files
- docker-compose.yml
-
assembly.py
18.64 KiB – dc0970c915e15e4356a54ee592ec0c10aa39db0f31e33ddc50a38d5f80897dea -
challenge.py
1.12 KiB – f9a8144c45c430c7dac2424757d3de2012cc3d3f5c0f017d8677d06f735151f2 -
machine.py
11.31 KiB – 216f14947d8daedfc71175035487674a0687d5b66ecedb61120330df1ebceff0
Author
![](https://hackropole.fr/img/authors/neige.3e841485463d7e6e20ade70a39cf09399c28592a6d59f6a19b4914f18616c9ec.png)
Challenge Instructions
- First, download docker-compose.yml:
curl https://hackropole.fr/challenges/fcsc2023-hardware-asm-comparaison/docker-compose.public.yml -o docker-compose.yml
- Launch the challenge by executing in the same folder:
docker compose up
- Then, in another console, access the challenge with Netcat:
nc localhost 4000
In case you encounter problems, please consult the FAQ.
Flag
Submit your solution
You can submit your writeup for this challenge. Read the FAQ to learn how to proceed.
You need to be logged in to submit a writeup.