encryption

Secure data type to store password in a VBA.NET forms app in Systems.Setting

Need to store the username and password for an outside application inside of a windows forms vb.net app. For initial testing, I just set the settings type to "Text", but want more security. There are System.Security and Encryption types available, but not sure where to begin. Any suggestions on how to Add, Update, and Delete the values...

Web service encryption.

We developed a web service which is accessed by various platforms clients, for example it is requested by c++ and Java enabled clients. I want to use simple, effective encryption Algorithm which is easily decrypted by JAVA - C++ and JAVA script based clients. ...

Turn an byte encoded Key back into it's original ECPublicKey in Bouncy Castle

In Java I have a ECDH public Key that I am sending as a byte array. Once I have received the byte array how can I turn it back into a public key? I am using Bouncy Castle but a Java solution would be just as useful. Thanks ...

Difference between a keyed hash and a non-keyed hash?

I've read a few articles about cryptography in .net, which leads me to the following question, what is the difference between a keyed hash and a non-keyed hash? ...

What's the Java JCE equivalent for this C OpenSSL encryption function?

I am writing a Java implementation of an app originally written in C. I can't modify the C version, and the Java version must share encrypted data with the C version. Here's the relevant part of the C encryption code: makekeys(password,&key1,&key2); /* turns password into two 8 byte arrays */ fill_iv(iv); /* bytes 8 bytes of randomness...

My CipherOutputStream fails silently

I'm trying to encrypt some binary data in Java with a public key as described on this useful page: http://www.junkheap.net/content/public_key_encryption_java As directed by the page, I created public and private keys using the commands: openssl genrsa -aes256 -out private.pem 2048 openssl rsa -in private.pem -pubout -outform DER -out p...

Symmetric Key to Asymmetric key handoff

I'm not a cryptography expert, I actually only have a little bit of experience using it at all. Anyways, the time has come where one of my applications demands that I have some encryption set up. Please note, the program won't be managing anything super critical that will be able to cause a lot of damage. Anyways, I was just trying to...

Is file encrption different from content encryption

Is there any difference between encrypting a file and encrypting the content of the file. If so, how to do the both. ...

Encrypting a message using ECDSA in OpenSSL

How do I set the private key for encrypting messages when using ECDSA in OpenSSL programmatically? I have the following code: static int create_signature(unsigned char* hash) { EC_KEY *eckey=NULL; EC_GROUP *ecgroup=NULL; EVP_PKEY *evpkey=NULL; unsigned char *signature=NULL; point_conversion_form_t form = POINT_CONVERSION_UNCOM...

Django urlsafe base64 decoding with decryption

I'm writing my own captcha system for user registration. So I need to create a suitable URL for receiving generated captcha pictures. Generation looks like this: _cipher = cipher.new(settings.CAPTCHA_SECRET_KEY, cipher.MODE_ECB) _encrypt_block = lambda block: _cipher.encrypt(block + ' ' * (_cipher.block_size - len(block) % _cipher.block...

Oracle Transparent Data Encryption undecrypted access

Can I set up an Oracle Database in a way that all of the following statements are true a) certain columns, potentially all columns are encrypted, so that direct file access to the database file wouldn't allow an attacker to retrieve any records b) the encrypted columns are transparently decrypted for authorized user, where authorizatio...

Manual password encryption

There are several ways to secure passwords with an automated encryption algorithm, but sometimes it's best to write it down on paper and keep the paper itself secured. Hackers can't easily get to paper. However, if someone finds that paper, they can see the passwords plainly. What's a non-automated method of securing information on a ...

Encrypt / Decrypt in asp.net using RsaProtectedConfigurationProvider

The encryption worked properly. But now i am getting an error that says "RsaProtectedConfigurationProvider Bad Data" When checked, i came to know that we need to run the command: aspnet_regiis -pa "NetFrameworkConfigurationKey" "NT AUTHORITY\NETWORK SERVICE" My question is, if I run this command in my production environment, will it af...

What's wrong with this PHP4 class to do AES encryption?

When I decrypt something encrypted with this function, the decrypted version doesn't equal the original. class AES256encryption { var $secret = ''; var $cipher_key = ''; function AES256encryption($secret='') { if (empty($secret)) { global $secret; if (empty($secret)) { ...

RC4 encryption - CommonCrypto (Objective-C) vs PHP

Hi, I have a XML file on a server encrypted with the RC4 algorithm (http://rc4crypt.devhome.org) function encrypt ($pwd, $data, $ispwdHex = 0) { if ($ispwdHex) $pwd = @pack('H*', $pwd); // valid input, please! $key[] = ''; $box[] = ''; $cipher = ''; $pwd_length = strlen($pwd); ...

Actionscript one way encryption

Hi all. Is there a built in method in Actionscript 3 that allows you to create a hash of a string. Like MD5 and SHA1. Thanks. ...

PHP encryption and decryption

Hello guys, Please I need your help, Here is my encryption codes in PHP, it works fine but I don't know how to decrypt it in PHP. I need to get the actual value back. I have similar code in c# and I was able to get the same results. But I need to decrypt the value. <?php $DATA= 'james' ; $KEY= 'moveme'; $hash = hash_hmac("sha256", ...

encryption and decryption that work for both c# and php

Is there any encryption and decryption Algorithms that work for both php and c#? Please I need a sample codes ...

Cannot decrypt data with C# that was encrypted using PHP (Rijdael-128)

I decrypt data using PHP with this code: $content="1234"; $cp = mcrypt_module_open('rijndael-128', '', 'cbc', ''); $iv = mcrypt_create_iv(16, MCRYPT_RAND); $key = pack("H*",md5('a')); mcrypt_generic_init($cp, $key, $iv); $encrypted = mcrypt_generic($cp, $content); echo base64_encode($key)."\n"; echo base64_encode($iv)."\n"; echo base64_...

C# simple encryption

Hi' I'm learning C# (as a hobbyist) and am trying to figure how to write a simple encryption program. Converting characters from ASCII is fine, got that sorted, but it is the shift I am stuck on. If I want to code for (n + 3) for example, what line of thought should I be following? ...