encryption-asymmetric

Should one use Cryptographic message syntax (CMS) for this task?

孤者浪人 提交于 2019-12-03 20:21:32
I've the task to transfer small binary messages (1 or 2 kb long) between a desktop application and mobile devices. The messages should be encrypted asymmetrically (RSA for instance). From what I've learned one should use a hybrid cryptosystem for this kind of task: Generate random symmetric key Encrypt plain text with symmetric key (using AES for instance) Encrypt symmetric key with public key Transmit cipher text and encrypted symmetric key I'd like to not invent an own format for storing the cipher text and the encrypted symmetric key. So I stumbled over CMS standard (Cryptographic message

What is the performance difference of pki to symmetric encryption?

巧了我就是萌 提交于 2019-12-03 16:59:46
问题 We are looking to do some heavy security requirements on our project, and we need to do a lot of encryption that is highly performant. I think that I know that PKI is much slower and more complex than symmetric encryption, but I can't find the numbers to back up my feelings. 回答1: Yes, purely asymmetric encryption is much slower than symmetric cyphers (like DES or AES), which is why real applications use hybrid cryptography: the expensive public-key operations are performed only to encrypt

Are public key and private key interchangeable?

只谈情不闲聊 提交于 2019-12-03 16:27:15
问题 On the one hand, I hear people saying that the two keys are totally interchangeable, the first one will decrypt what the second one encrypted. This makes me think that the two keys are interchangeable. But on the other hand, RSA generated keys appear to have different length, and on another topic encrypting with a private key was called “signing” and was deemed less safe than encrypting with a public key. (2) On top of that comes the idea that the private key should be kept undisclosed when

Any tutorials on public key encryption in java? [closed]

允我心安 提交于 2019-12-03 15:37:47
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 3 years ago . I've been able find information on symmetric encryption and hashing but I've been having quite a bit of trouble finding much information on any sort of public key encryption for java. What I'd like to do is make a very simple proof of concept program that takes a string ( or a file I suppose), encrypts it with a

Seckey from public key string from server in Swift

爱⌒轻易说出口 提交于 2019-12-03 15:14:30
I want to encrypt data using RSA , I tried to generate the key in my code and it's working , But what I actually need is to get the public key as a string from server and then use it as Seckey so I can use it to encrypt data using RSA, I tried this code: //KeyString is the string of the key from server let KeyData = (keyString as NSString).dataUsingEncoding(NSUTF8StringEncoding) as NSData! var cert : Unmanaged<SecCertificateRef>!; var policy : Unmanaged<SecPolicy>!; cert = SecCertificateCreateWithData(kCFAllocatorDefault, KeyData); policy = SecPolicyCreateBasicX509(); var status : OSStatus =

JWT Keys - Asymmetric and Symmetric

我与影子孤独终老i 提交于 2019-12-03 12:16:12
I understand the difference between symmetric and asymmetric keys. I understand that the keys are used to calculate the signature and then verify them. However diving a little deeper, I'd like to understand a bit more which I'm having trouble finding online. Are the keys given to the consumers to verify the contents? Wouldn't that give consumers the ability to change the JWT contents if symmetric keys are used? When asymmetric keys are used is the signature calculated with the private or public key? Is the consumer given the public/private key? Thanks Symmetric keys are only to be used in a

Questions about the NaCL crypto library

送分小仙女□ 提交于 2019-12-03 07:48:38
问题 I was looking for libraries to implement an encryption system and was interested in using the NaCl: Networking and Cryptography library specifically the box function. Obviously, it uses symmetric encryption XSalsa20, Curve25519 for public-private cryptography and Poly1305 for authentication as the primitives for it. However, the documentation looks to be insufficient in the way the they've been used. For example, it mentions that to compute the key it uses the sender's private key and the

Delphi asymmetric encryption

本秂侑毒 提交于 2019-12-03 06:55:18
I'm looking for a Delphi implementation of an asymmetric encryption algorithm without any dependencies on external DLLs. Is there any available? My goal is to encrypt/decrypt a string (or array of bytes) using a public/private key pair. SecureBlackBox from Eldos offers a native, comprehensive solution - including certificate management and access to external crypto devices (i.e. USB tokens) LockBox is now improved. It allows long keys for RSA, AES cipher and is in active development. It is free, Open Source and 100% native code with no DLLs. You can try Lockbox - http://sourceforge.net

RSA Encryption in Java: Cross Platform Issues?

核能气质少年 提交于 2019-12-03 06:14:00
问题 The Situation I'm working with RSA encryption in Java. I'm trying to encrypt data on an HTC Saphire (32B) developer phone equipped with Cyanogenmod's Android 2.2 and then decrypt said data on a 64 bit server running Mandriva Linux 2010. I am using the same public key, private key pair on both machines, can correctly encrypt/decrypt data on the Android phone, can correctly encrypt/decrypt data on the Linux server, but I am unable to encrypt data on the phone and then decrypt it on the server.

Any tutorials on public key encryption in java? [closed]

自古美人都是妖i 提交于 2019-12-03 06:08:00
I've been able find information on symmetric encryption and hashing but I've been having quite a bit of trouble finding much information on any sort of public key encryption for java. What I'd like to do is make a very simple proof of concept program that takes a string ( or a file I suppose), encrypts it with a public key and then decrypts it with a private key. Any tutorial links or examples would be appreciated. I just want to make something demonstrating how you can use public key encryption in Java. Loki There are quite a few resources on the web about that. Basically it turns around the