Questions tagged [aescryptoserviceprovider]

66 questions
2
votes
1 answer

Where to specify key and IV value when doing AES encryption/decryption in Android?

I am working on AES encryption and decryption in android. I have an Audio file which is encrypted using AES/CBC. I have the key and IV (initialization vector). I have read some links. From this SecretKeySpec skeySpec = new SecretKeySpec(raw,…
Karthikeyan Ve
  • 2,151
  • 2
  • 19
  • 36
2
votes
1 answer

Key does not exist when trying to decrypt using RSA

So, I am creating a simple "web chat", using TcpClient and TcpListener class. I want all data sent to be encrpyted, and I am using AES encryption. So first I have to make sure AES key from server is securely sent to client. I am trying to achieve…
2
votes
0 answers

Generate key using Pass Phrase or AesCryptoServiceProvider?

We using AES encryption to encrypt the data. Generating a key once in a year using some app(i.e console) so which way i have to choose to generate the key? 1. Do we need to generate the key using the Pass Phrase method? 2. Or we have to choose the…
2
votes
1 answer

How use AES/ECB/PKCS7Padding algorithm in Windows Phone 7?

I am new in windows phone development. How can I use AES/ECB/PKCS7Padding algorithm in WP7 ?. While googled I saw many suggested about Bouncy Castle. But I did not clearly understood about this Bouncy Castle. Is this an algorithm ?. I need to…
1
vote
2 answers

Aes Encryption... missing an important piece

I have a method in my static Encryption class that looks like this: public static byte[] EncryptString(string toEncrypt, byte[] encryptionKey) { var toEncryptBytes = Encoding.UTF8.GetBytes(toEncrypt); using (var provider =…
Jeremy Holovacs
  • 19,993
  • 29
  • 99
  • 234
1
vote
0 answers

ECDiffieHellman inherits from AsymmetricAlgorithm but doesn't implement ICspAsymmetricAlgorithm?

I'm trying to understand the cryptography implementation (the big picture) in .NET and its relation to CSP, like what asymmetric algorithms are available for CSP, so if I want to implement a solution that uses CSP, what options I have. I read this…
mshwf
  • 5,595
  • 11
  • 42
  • 100
1
vote
1 answer

Trying to decrypt an encrypted key generated using AES 256(AES/ECB/PKCS7Padding) algorithm in nodejs using crypto

I tried using aes256,aes-cross, and crypto. But I was not able to decrypt the key which is encrypted using AES 256 (aes-256-ecb) with PKCS7 padding. I ended up with the following mentioned errors. Error: Invalid key length at…
1
vote
1 answer

is there a Java ECB provider?

Anyone know of a Rijndael-128bit ECB provider in Java??? Also, what's the difference between AES-128bit and ECB? or are they the same? (couldn't find answer any where else online)
Rafael
  • 993
  • 4
  • 14
  • 31
1
vote
0 answers

c# RijndaelManaged 10 times sower than Java equivalent (AES/CFB8/NoPadding)

While debugging the performance of my C# application I noticed that it's a lot slower than it's Java equivalence. After looking into it the problem seems to be caused by the encryption/decryption methods. I am forced to use AES encryption with mode…
Jpm100
  • 11
  • 2
1
vote
1 answer

Why does my AES-decrypted data have garbage bytes at the end?

I'm trying to use AesCryptoProvider to encrypt and decrypt byte arrays. Here are my encrypt and decrypt methods: public static byte[] EncryptAes(byte[] data, out byte[] key, out byte[] iv) { if (data == null || data.Length <= 0) throw…
1
vote
2 answers

Create 16 byte key for AES Encryption from Salt and Password in Node JS Crypto

I'm trying to match an AES 256 CBC encryption implemented in C# by using node JS crypto module. This is my C# code using System; using System.Security.Cryptography; using System.Text; public class Program { public static void Main() { …
Avinash
  • 1,580
  • 1
  • 13
  • 14
1
vote
1 answer

Module not found: Can't resolve 'react-native' in '/app/node_modules/react-native-aes-crypto'

I want to use react-native-aes-crypto but it need react-native. I install it but it continue to say that it can't find it. I have try to reinstall it, add his dependencies but nothing work. My package.json: { "name": "neko_web", "version":…
Tryliom
  • 101
  • 1
  • 17
1
vote
1 answer

Initialization vector size

(Image of code I couldn’t type it due to limited site access) I have an encrypted file that i encrypted using XILINX SDK. The key file used contains a 256 bit key and a 96 bit iv. I am attempting to decrypt the file using AesCrytopServiceProvider…
1
vote
1 answer

CryptoStream AES decryption failing with larger chunks

Here's a decryption method I'm using inside Unity3d. It works perfectly when I call it with 128 byte sized portions but fails when it gets say 256 bytes at a time. Should I call it in blocksize-chunks only? After further analysis, I thought that the…
1
vote
0 answers

AesCryptoServiceProvider - "Padding is invalid and cannot be removed" + c#

I have gone through the questions with the same issue but are of no help. I checked my code and it's same as they suggested. //Create the hash value from the array of bytes. byte[] KeyHashValue = SHhash.ComputeHash(Encoding.UTF8.GetBytes(key.Length…
Heena
  • 2,318
  • 3
  • 30
  • 55