public-key-encryption

.NET implementation (libraries) of elliptic curve cryptography

Please can you suggest any implementation of elliptical curve cryptography to be used on .NET platform? Also if you have used them, can you tell me the recommended curves that should be used? [EDIT] As @FatCat mentioned, its implementation is available in .NET framework 3.5 but that is only available on windows vista. Can you please s...

DSA public key system verification with Silverlight

I need to verify a DSA signature in Silverlight and since the runtime does not include the System.Security.Cryptography.DSA class I was wondering if anyone has an alternative? ...

How does two-way asymmetric encryption work?

Say we have Alice and Bob. Alice sends Bob a message she encrypted with Bob's public key. Bob is the only person who can decrypt it, using his private key. But how can he be certain the message came from Alice? Suppose he replies, encrypting his message using Alice's public key. Only Alice can decrypt the message. But how can s...

Is there a 8 bit block sized Public-Private key encryption algorithm?

I checked out TripleDES. It's block size is of 64 bits. Is there any algorithm for 8 bits block size? Thanks EDIT : I intend not to use this for perfect protection, but for a just-in-case situation where one who sees the code should not find the plaintext. So 8 bit is kinda okay for me. ...

BAD_UID error while exporting key in CryptoAPI

Hi all, I am writing a test application for Microsoft CryptoAPI. I want to export the secret key of one party using the public key of the second party, and then import that secret key as the second party's secret key (this sets up a shared secret key for communication). Here is my code: if(!CryptExportKey(encryptT->hSymKey, decryptT->hP...

pgp key information

can someone show a description of the information of what a pgp looks like if only the descriptions were there but not the actual information? something like (i dont remember if the values are correct): packet-type[4 bits], total length in bytes[16 bits], packet version type [4 bits], creation-time[32 bits], encryption-algori...

how to produce a key pair for 64 bit public key encryption

I need to generate a 64 bit public-private key pair but can't find out any standard algorithm....... How do I do that? Someone please reply asap ...

Using Public/Private keys in reverse

Hi, I have a situation where I need to make some data available for reading by anyone from a specific device, where the data is pre-loaded on the device, but I cannot allow anyone to create their own device and populate it with their own data in the same format. I know this sounds a little crazy, but there is a good reason! I was plan...

Confused about encryption with public and private keys (which to use for encryption)

I am making a licensing system when clients ask my server for a license and I send them a license if they are permitted to have one. On my current system I encrypt the license using a single private key and have the public key embedded into the client application that they use to decrypt the license. It works! Others have told me that...

Encryption Product Keys : Public and Private key encryption

I need to generate and validate product keys and have been thinking about using a public/private key system. I generate our product keys based on a client name (which could be a variable length string) a 6 digit serial number. It would be good if the product key would be of a manageable length (16 characters or so) I need to enc...

Getting IllegalBlockSize when trying to encrypt too much data

Here are my constants //Encryption fields /** Algorithm=RSA Mode=ECB Padding=PKCS1Padding*/ public static final String ALGORITHM_MODE_PADDING = "RSA/ECB/PKCS1Padding"; /** Algorithm=RSA */ public static final String ALGORITHM = "RSA"; /** Provider=BouncyCastle */ public static final String PROVIDER = "BC"; /** Key size for the public an...

How to send and receive encrypted email using PHP.

I work at a hospital and have developed a way to estimate the total patient financial responsibility for services, after insurance has paid it's obligation, and before any services are rendered. A lot of patients are calling for quotes, and I wanted to find a secure way to email those results to the patient at their request. I'm conside...

Rainbow tables as a solution to large prime factoring

In explanations I've read about public key cryptography, it is said that some large number is come up with by multiplying together 2 extremely large primes. Since factoring the product of large primes is almost impossibly time-consuming, you have security. This seems like a problem that could be trivially solved with rainbow tables. If ...

Encryption across the popular programming languages.

I have to implement something similar to PayPal IPN / Return URL. In my scenario , PayPal Gateway => My Server && Online Store => My Customer I have to push a very small piece of information through the Return URL in an encrypted format. I would like to generate something like Public Key and Private Key for each customer, and give the P...

Authenticating a user over HTTP (instead of HTTPS)

INITIAL NOTE: This is just for a personal tinkering project; I'm not writing enterprise security here, and if I were, I'd know better than to try to write my own scheme. :-D EDIT: To stress the above point, I tried to tag this under "iKnowThisWouldBeABadIdeaInRealLife", but SO wouldn't accept it because it was >25 chars. Just be aware...

How to generate ssh compatible id_rsa(.pub) from Java

I'm looking for a way to programmatically create ssh compatible id_rsa and id_rsa.pub files in Java. I got as far as creating the KeyPair: KeyPairGenerator generator; generator = KeyPairGenerator.getInstance("RSA"); // or: generator = KeyPairGenerator.getInstance("DSA"); generator.initialize(2048); ...

Public & Private Keys in .NET besides RSA

Hi All, Am I missing something obvious here (I hope I am), besides RSA, are there any other crypto methods in .NET that use a public & private key? Thanks! ...

How do I import a public key for encryption in C on Windows

I have a public key and I want to use it to encrypt a piece of data. I'm trying to import the public key in order to use it, but CryptImportKey gives me an 'invalic parameter' error. What's the problem? Here's my code: if( !CryptAcquireContext(&hProv, NULL, NULL, PROV_RSA_AES, CRYPT_VERIFYCONTEXT) ) { /* * Print error and re...

How to export a public key in OpenSSL/libcrypto?

Hi All, I've created an RSA key using: RSA_generate_key(2048, RSA_F4, NULL, NULL); Now I want to export the public key to another party B. Right now, I've just memcpy'd the entire RSA* struct and sent that over the wire, and B is able to use that to encrypt using RSA_public_encrypt(). But I think in this case I've actually exported t...

iphone OS! RSA Encryption with public key generated by Bouncy Castle (Java)

Hi, I'm developing an application on iphone. I had an application on Java using encryption (RSA) and I created a Private Key and Public Key. I want use the Public Key in Java application on iphone. For Ex: My Public Key is byte[] publicKey = {0x01,0x02}; How can I use my publicKey to encrypt data on iphone? I saw CryptoExercise, but i ca...