Skip to content
This repository was archived by the owner on May 3, 2026. It is now read-only.

Commit 36a125b

Browse files
committed
Removed test code
1 parent 0bd3776 commit 36a125b

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

EncryptPayload/Source.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
#include <stdio.h>
33
#include <fstream>
44
#include <vector>
5-
#include "rc4.hpp"
65

76

87
void encrypt(unsigned char* data, size_t length, const char* key) {
@@ -13,17 +12,14 @@ void encrypt(unsigned char* data, size_t length, const char* key) {
1312
}
1413

1514
void decrypt(unsigned char* data, size_t length, const char* key) {
16-
encrypt(data, length, key); // XOR encryption is reversible, so we can reuse the same function
15+
encrypt(data, length, key);
1716
}
1817

1918
int main(int argc, char* argv[])
2019
{
2120
const char* payloadPath = argv[1];
2221
const char* encryptionKey = argv[2];
2322

24-
struct rc4_state* s;
25-
s = (struct rc4_state*)malloc(sizeof(struct rc4_state));
26-
2723
std::ifstream payload(payloadPath, std::ios::binary);
2824
std::vector<unsigned char> payloadBuffer(std::istreambuf_iterator<char>(payload), {});
2925
payload.close();

0 commit comments

Comments
 (0)