Questions tagged [rc4-cipher]

RC4 in cryptography is a widely used stream cipher. It's most common application is the WEP security algorithm. RC4 is fairly simple to understand and implement, on the other side, however, strong attacks on RC4 are known.

143 questions
1
vote
0 answers

RC4 decryption with key in Python

I pulled this code from here for asp http://bytes.com/topic/access/insights/906671-rc4-encryption-algorithm-vba-vbscript, which i then run thru base64. I am wonder if anyone can help me figure out how to write the decryption piece but in Python. As…
Jim
  • 613
  • 6
  • 16
  • 25
1
vote
3 answers

Objective-C RC4 Decryption

I am new to Objective-C, but am an experienced developer (C#), but I can't figure this out: I have a string which is RC4 encrypted, and I need to decrypt it using Objective-C on the iPad (iOS 5.0). I have looked all over the net for a working…
Greg M.
  • 332
  • 4
  • 11
1
vote
1 answer

How to encrypt any js file (in browser) using CryptoJS?

I have a task: Implement a program that encrypts a file using a strong symmetric cipher. After researching the requirements and features, I chose the RC4 algorithm and its implementation in the CryptoJS…
Alexander
  • 291
  • 4
  • 13
1
vote
1 answer

Java 17 Update - Cannot find key of appropriate type to decrypt AP-REQ - RC4 with HMAC

I have a productive Java application using Kerberos for SSO. After I update Java from version 16 to 17, I run into the following Error: Cannot find key of appropriate type to decrypt AP-REQ - RC4 with HMAC Caused by: GSSException: Failure…
flavio.donze
  • 7,432
  • 9
  • 58
  • 91
1
vote
0 answers

How i solve this rc4 encryption

def get_prg(plaintext_size, k): j = 0 S = list(range(32)) for i in range(32): j = (j + S[i] + ord(k[i % len(k)])) % 32 S[i], S[j] = S[j], S[i] return S def fake_rc4(plaintext, keystream): i = 0 j = 0 i =…
Amit Hadad
  • 35
  • 5
1
vote
1 answer

Inconsistent encryption and decryption with OpenSSL RC4 in C++

First off, I understand that RC4 is not the safest encryption method and that it is outdated, this is just for a school project. Just thought I put it out there since people may ask. I am working on using RC4 from OpenSSL to make a simple encryption…
Shafi Kamal
  • 91
  • 3
  • 10
1
vote
1 answer

RC4 decryption not working properly. Encryption is totally working and I have described my problem in the para below

I am currently working on combining 3 cryptography algorithms namely AES,DES,RC4. I have successfully done encrytion and stored the key and cipher text in a file but as in my code of RC4 cipher is an integer array it needed to be converted in…
1
vote
1 answer

Resolving Indexerror In Python RC4 Cipher Code

I'm fairly new to programming in python and have been tasked with creating a RC4 cipher in python. This implementation utilizes numpy. If someone could help me resolve this error in the cipher code it'd be greatly appreciated. RC4 Program def…
1
vote
1 answer

When deciphering with RC4, what does it mean to skip bytes?

I have the binary data that I need to decipher, the algorithm (RC4) and the key. However, to decipher the data, one instruction I got is that "the length of the key initially gets skipped" or that "len bytes are skipped initially". What does this…
Maxime Dupré
  • 5,319
  • 7
  • 38
  • 72
1
vote
0 answers

My JavaScript RC4 code ruins my original text

I've tried everything from changing a few variables, to the integers and also trying to look for answers online. I know that RC4 is not that secure, but I only need it for a simple project. The issue is whenever I try to encrypt a huge character…
1
vote
0 answers

Is there a version or modification of RC4 that will produce encrypted strings that are safe for use as cookie values

I need to obfuscate sensitive information like email addresses written to visitor cookies on my website and was hopeful about RC4. But I had written a simple test to compare each character in strings output from a standard RC4 routine against all…
Randy
  • 301
  • 2
  • 11
1
vote
0 answers

How to check if secret key is correct

i am doing RC4 encryption in Java. However, i am not sure if my secret key output is correct. My codes are shown as below. Do advise, thanks! Refer to my output below. BigInteger newformula = gwithoutspaces.modPow(newx, pwithoutspaces); …
Stella
  • 39
  • 1
  • 3
1
vote
1 answer

Openssl RC4 vs C++ RC4 (with salt)

I am working some more with an RC4 C++ program to be compatible with the command line arguments. I was wondering if somebody can point me in the direction of some decent documentation of how the command line openssl rc4 uses the salts when…
Chris
  • 95
  • 9
1
vote
1 answer

Difference between openssl rc4 command line encrypt and cpp file implementing rc4

I am working on trying to encrypt a text file via RC4 with a cpp file that I wrote with openssl/rc4 headers, and then decrypt via the command line to show that my implementation is correct. My terminal command for the file is below, and the cpp file…
Chris
  • 95
  • 9
1
vote
1 answer

RC4 Using VBScript and Python

I've been trying to learn VBScript, and gave myself a bit of a challenge. I wanted to create a function in VBScript that encrypts something in RC4, and decrypts in Python (essentially the same process/algorithm, but I wanted to verify that it was…
Billy Thorton
  • 213
  • 1
  • 4
  • 12
1 2
3
9 10