Questions tagged [encryption-symmetric]

A type of encryption where the same key is used to encrypt and decrypt the message.

Symmetric encryption is the oldest and best-known technique. A secret key, which can be a number, a word, or just a string of random letters, is applied to the text of a message to change the content in a particular way. This might be as simple as shifting each letter by a number of places in the alphabet (known as the Caesar Cipher), or as complicated as the Advanced Encryption Standard, which is used in some modern cryptography. Anyone who knows the key can either encrypt or decrypt a message.

Note that symmetric encryption does not require that the encryption and decryption key be identical, but rather that both keys derive from the same knowledge. For example, a letter-shifting cipher might require that "A" be enciphered as "G" - the opposite operation would be needed to decrypt.

736 questions
-1
votes
1 answer

Is there something special to encrypting a string into another file using a custom dictionary?

I made a custom dictionary in Python changing the alphabet (both upper and lowercase) into symbols and numbers. I am trying to copy the content of one text file to another but encrypt it in the custom dictionary. For example, if the file says…
-1
votes
1 answer

Speed up AES_CBC mode (using AES_ECB mode)

I want to implement AES_CBC mode encryption, using ECB encoder from Crypto package. But my code run quite slow (about 1s for 1MB data, while it is just 0.02s when encrypt with AES_CBC mode from Crypto package). Below is my code, any recommend for…
-1
votes
1 answer

why am I getting cryptography fernet InvalidToken when using the same key

Hello so I am making a password manager and I want to encrypt the password file, so I generate and create the first password and when I read it and decrypt it reads it. And then when making another password it creates it but then when decrypting it…
user13494858
-1
votes
1 answer

Datapower encrypted text Decrypted value of CBC algorithm consists of input and unwanted characters in java

Am trying to Decrypt an encrypted text from data power in Java using below code. Am using symmetric key mechanism. Thee below code is able to Decrypt the data but gives me a data with unwanted characters f ollowed by plain text. I tried to substring…
gautham
  • 87
  • 2
  • 12
-1
votes
1 answer

Storing API key

I am building a website that’s gonna have a pay system that works with the mollie API. In particularly the website needs to send users a payment link for their ordered products. To accomplish that mollie needs to authenticate with a api key. So I…
Stan
  • 629
  • 7
  • 18
-1
votes
1 answer

Encrypting the vector of 0 and 1s

I am about to create a vector of size n, with zero and ones. I want to encrypt all the elements of the vector, but I am wondering if encryption of the elements reveals information about the zero and ones. Is there any specific cryptosystem at which…
user3126804
  • 119
  • 3
  • 10
-1
votes
1 answer

Which tool can I use to encrypt bacpac file using azure key vault

I exported my azure SQL Managed instance to a Bacpac file using SQLPackage, Now I want to store it on a azure file storage. Before I want to copy the bacpac to the file storage, I want to encrypt it using a Secret from Azure key vault. SQLPackage…
-1
votes
1 answer

Encryption is not working in Swift4.2 using CommonCrypto. Throwing error 4301

I have been trying to implement encryption using CommonCrypto library in swift 4.2. But no luck, ending up with some unknown error. Somebody please look at this code and help me. func encrypty(data value: String) -> EncryptionResult { guard var…
Vinay Hosamane
  • 346
  • 1
  • 5
  • 15
-1
votes
1 answer

Encryption result only in alpha numeric

I want to encrypt a String to an cipher which consists only of alphabets (a-z/A-Z) and numbers(0-9). I doesn't want it to have any other characters (=, &, !.. etc). Is there any way to achieve it? If so, can please someone help me out. A java code…
-1
votes
1 answer

How to decrypt string in c# or sql server using symmetric key

Below is my scenario I receive encrypted value(using DBMS_CRYPTO.ENCRYPT_3DES_2KEY) from client in text file ( Encryptions done in Oracle) I receive the key(AES192 30 character key) from client which is used for encryption. I am using SQL Server…
RobertKing
  • 1,853
  • 8
  • 30
  • 54
-1
votes
1 answer

Symmetric and Asymmetric Cryptography

I'm looking for an advice regarding cryptography. I'm working on a .Net application which I need to create a license for it, so I plan to create an encrypted license file which my application will use to know if it is licensed or not. Handling…
-1
votes
1 answer

Can symmetric cryptography be used for providing digital signatures?

I was wondering what the main reason was for symmetric keys not being used in this context?
Martin l
  • 23
  • 6
-1
votes
3 answers

Bitwise Operations on type byte vs byte[]

Here is the bit of code I'm working with: byte[] encodedBytes1 = null; byte[] encodedBytes2 = null; try { Cipher c = Cipher.getInstance(encryptationMode); c.init(Cipher.ENCRYPT_MODE, key); encodedBytes1 =…
John
  • 65
  • 1
  • 1
  • 10
-1
votes
2 answers

(C language) Garbled decryption in AES-CTR based encryption decryption tool

The decryption and encryption code (included below) may be possibly wrong. They're compiling error free, however, the decrypted file is not same as the plaintext file. It is garbled. I am trying to find out why it is garbled. I doubt my code to be…
-1
votes
1 answer

Error during encrypt a file using Mcrypt DES in php

i want to encrypt a text file. below is my code.But i am getting function error during run.
bKashOST
  • 149
  • 4
  • 11