Skip to content

Instantly share code, notes, and snippets.

View Amrt1n3zm's full-sized avatar
🚛
I may be slow to respond.

Alejandro Amrt1n3zm

🚛
I may be slow to respond.
View GitHub Profile
@Amrt1n3zm
Amrt1n3zm / Assignment1.md
Created April 6, 2022 02:45 — forked from debanshu/Assignment1.md
Assignment1 Cryptocurrency explanation by Felipe

Reproduced as is from Felipe Faria's post

The first thing you must do before starting the assignment is understanding the assignment. For obvious reasons I can't type here a "step-by-step procedure" of the assignment, but I can go over the classes and maybe clarify the instructions a bit better for you and anyone else having difficulties.

Your job for this assignment is to write the TxHandler class, which stands for Transactions Handler. This class has three functions in which you must write it yourself; TxHandler, isValidTx, and handleTxs. As the names suggest, one will initiate the class, one will verify the transactions, and the other will handle the transactions. Now I'm going to assume you have a basic understanding of Java, and you comprehend the idea of classes and functions.

These are the files given to us for the assignment:

Crypt
package info.osom.sandbox;
import javax.crypto.*;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.SecretKeySpec;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.security.InvalidAlgorithmParameterException;
import java.security.InvalidKeyException;