Questions tagged [3des]

In cryptography, Triple DES, or 3DES, is the common name for the Triple Data Encryption Algorithm (TDEA or Triple DEA) block cipher, which applies the Data Encryption Standard (DES) cipher algorithm three times to each data block.

is the common name for the Triple Data Encryption Algorithm (TDEA or Triple DEA) block cipher in cryptography, which applies the Data Encryption Standard (DES) cipher algorithm three times to each data block. This protocol has long been deprecated in favor of stronger encryption algorithms.

357 questions
1
vote
2 answers

Error in converting to hex and then back to normal string

I am using the following code for a my sampled 3DES encryption I am using: package Algorithms; import java.io.UnsupportedEncodingException; import java.security.InvalidKeyException; import java.security.MessageDigest; import…
sasidhar
  • 7,523
  • 15
  • 49
  • 75
1
vote
0 answers

Is it possible to disable weak ciphers in C# programmatically?

I want to disable CBC ciphers in our client application. The application is built on .NET Framework 4.7.2 and uses TLS 1.2 to connect to server. Is there any possibility to do this without changing the registry?
1
vote
1 answer

How to decrypt a string in PHP that was encrypted in Java?

I tried to decrypt en encrypted string in JAVA with to code below. SecretKey secretKey = new SecretKeySpec(build3DesKey(key), "DESede"); Cipher cipher = Cipher.getInstance("DESede"); cipher.init(Cipher.DECRYPT_MODE, secretKey); byte[] b =…
1
vote
0 answers

3DES fails with key in Android hardware-backed keystore

I'm trying to get 3DES decryption with the key stores in secure hardware on Android (Trusted Exceution Environment or StrongBox) working. From what I've read 3DES should be available with KeyMaster 4.0 [1, 2], but I get a NullPointerException:…
1
vote
1 answer

Encrypt using 3DES and PHP's openssl_encrypt()

I'm trying to implement 3DES in PHP (v7.4.6) using openssl_encrypt() but am having problems generating the correct ciphertext output. (I am aware that 3DES is insecure, but I must use it because the legacy system I'm connecting to requires…
kmoser
  • 8,780
  • 3
  • 24
  • 40
1
vote
0 answers

nmap ciphers scanning result is inconsistent

I am working on preventing SWEET32 Attack. I have disabled weak ciphers. When I run the below comments multiple times. nmap -p 443 --script ssl-enum-ciphers example.com I am getting inconsistent results. Can any one explain me, "How to get constant…
1
vote
0 answers

How to keep 3DES keys secure in Android

I need to keep and use a 3DES key in an Android application in order to communicate with a legacy sytem. I would like to use the Android Keystore provider for its high security features, but it seems it doesn't support 3DES. My understanding is that…
Belvito
  • 33
  • 1
  • 3
1
vote
1 answer

TransformFinalBlock with TripleDes(3DES) - DESMode.ECB in Dart/Flutter

I tried and looked for a solution to my problem, but I didn't find anything that worked. I have a C# program that works perfectly. My task is to turn this program into Flutter, but I can't. ** The code (in C#) that works is this: ** private…
1
vote
1 answer

Java SecretKey and replicating it's behaviour in C#

I am trying to replicate the encryption logic found in a Java library in a C# application. The Java contains two methods which I have managed to replicate in C#. I get the same results in each program for any set of data. createKey(byte data1[],…
Karle
  • 880
  • 2
  • 12
  • 21
1
vote
1 answer

3DES crypto on PHP produces different result from NodeJS

I'm building a checkout that need credit-card 3DES-CBC encryption, but I am getting different result on PHP and NodeJS. PHP code: '0000000000000000', 'CartaoMesAno' => '00/0000', …
1
vote
0 answers

Python3 Base64 Encode PyDes 3DES Object

Hi I am trying to create a function whereby a token is generated by the server that utilises 3DES which is then Base64 encoded and sent to a client application. I am trying to use pyDes to encypt the string using a key and then base64 encode that…
3therk1ll
  • 2,056
  • 4
  • 35
  • 64
1
vote
1 answer

3DES crypto on Python produces different result from Nodejs/Java

Im bulding a checkout that need creditcard 3DES Crypto, but I getting differente result on Python and NodeJs. Python code: (im using pycryptodome package) import binascii import base64 from Crypto.Cipher import DES3 import json iv =…
1
vote
1 answer

ToadStudio passwords in settings file, security concern

I need to share a connections setting file for ToadStudio SQLeditor. I do have some concerns about the passwords that are stored in the settings file. The file currently looks like this: 3
Lenny Markus
  • 3,398
  • 2
  • 24
  • 30
1
vote
1 answer

C# Decrypt 3DES method to Swift language

I have a code in C# and I actually convert it on iOS Swift. I have this function in C#: public static string DecryptString(string Message) { byte[] Results; System.Text.UTF8Encoding UTF8 = new System.Text.UTF8Encoding(); …
1
vote
0 answers

Coverting Simple3Des(VB.net) encryption-decryption code to python

I'm have a plain JSON text which is encrypted using Triple-DES in Visual Basic(code provided below), now I'm trying to decrypt it using python language. when I test it I'm getting the wrong output. I think there is any padding issue because I didn't…