encryption

ManyToOne reference with encrypted fields gives doesn't exist error using Jasypt

I have a problem on the following situation: In my Spring, Hibernate application I got a User Entity and a UserCategory Entity. The table of the user entity got a username as identifier. This indentifierfield can't be encrypted because this table is also used by an older program without the possibility to do this. To make a ManyToOne...

Error implementing Jasypt with Hibernate 3 and Struts 2

Hi, I'm trying to encrypt passwords in a webapp using Jasypt with hibernate 3. I followed the instructions on the jasypt website. Here's my hibernate mapping : <hibernate-mapping package="webapp.entity"> <typedef name="encrypted" class="org.jasypt.hibernate.type.EncryptedStringType"> <param name="encryptorRegisteredName">strongH...

Equivalent of PHP's crypt function in Java

I am migrating my PHP code to Google App Engine - Java. So I need an equivalent of PHP's crypt function in Java, since I have stored all the passwords of registered users using crypt in my DB. Edit 1: Here is my php code for encrypting passwords : $password = "test123"; $pwd = crypt($password,$password); echo $pwd; Output is...

secure way to deliver password over URL?

hey guys, i wonder if there's a secure way to deliver a password with an URL (like ?p=mypassword) how can i encrypt and decrypt such a password so it's secure. i guess md5 is not working in my case because the password must still be readable. It's an FTP passwort which gets passes along to the ftp_connect. i think md5 doesn't work in t...

What's the equivalent of C#'s GetBytes() in Python?

Hi, I have byte[] request = UTF8Encoding.UTF8.GetBytes(requestParams); in a C# AES encryption only class that I'm converting to Python. Can anyone tell me the Python 2.5 equivalent(I'm using this on google app engine? Example inputs: request_params: &r=p&playerid=6263017 (or a combination of query strings) dev_key: GK1FzK12iPYKE9...

Equivalent of PHP's crypt function in actionscript

I am migrating my PHP code to Google App Engine - Java. Since I couldn't find an equivalent function of crypt in Java, I can do without it if I find an equivalent function in actionscript. Edit 1: Here is my php code for encrypting passwords : $password = "test123"; $pwd = crypt($password,$password); echo $pwd; Output is (On Windows...

Rijndael File Chunk Encryption?

Hi, I am writing a C# class that reads a file and encrypts using Rijndael algorithm. While testing with a 600MB file, i gets OutOfMemoryException, so planned to read the file in small chunks of 10MB each. Now the problem is that, the decryption process fails for the file whose bytes were encrypted as small chunks. My question is, whe...

Encrypted columns with Entity Framework

Anyone figured out a good way to pull encrypted values from db through entity framework 4? I got a MySql db with some columns encrypted with des_encrypt and need to be able to get those values as easy as possible, and also of course, update and insert them. I think it's quite strange there doesn't seem to be in built support for this i...

how to check whether data is already encrypted or not

Hi, I am using RijndaelManaged in my current project to encrypt data , is there any way tht I can check whether the data is already encrypted or not so i don't end up encrypting it twice? ...

Encrypt in ActionScript3 and Decrypt in asp.net c#

Hi, I need to send data from flash to the server, so I'm looking for a flash ActionScript 3.0 script that will encrypt a text and a C# .net script that decrypt the text. Can anyone help me here ? ...

Jasypt StandardPBEStringEncryptor setting password in spring bean configuration file

When using Jasypt's StandardPBEStringEncryptor we have to set password explicitly in spring bean configuration file. Is it ok and secure to have the password in the bean configuration file? Will it be a problem in PCI Compliance to store the encryptor password? ...

Problem using AES and base64_encode the result

Hi, I am trying to encrypt a string then covert it into a base64_encode string to be passed to a website so that it can decrypt it. My functions below dont seem to be working correctly and it won't decrypt the base64_encode string back to the original string. Anyone see the problem? Thanks public static string EncryptToString(stri...

java equivalent of Perl Crypt::CBC

use Crypt::CBC; my $crypt = Crypt::CBC->new(-key => "password", -cipher => "Crypt::Blowfish"); print $crypt->encrypt_hex('s'); How do I get the same result using java? Thanks in Advance. ...

Hashing SSNs and other limited-domain information

I'm currently working on an application where we receive private health information. One of the biggest concerns is with the SSN. Currently, we don't use the SSN for anything, but in the future we'd like to be able to use it to uniquely identify a patient across multiple facilities. The only way I can see to do that reliably is throug...

Identify GSM encryption algorithm

I would like to find out whether my android phone (ADP) is using A5/0, A5/1 or A5/2 at a specific time. How can I achieve this? ...

Check password before decryption.

I'm writing small program (C++) to encrypt/decrypt files. Before decryption I would like to check if password given by user is correct. My idea: Add at the beginning of file some string (for example: "GOOD"); Encrypt file When decrypting first decrypt the beginning of file and check for "GOOD" string Is this correct? ...

User security in the database of my website

Lets say i have a website mysite.com that will store some sensitive personal data (bank related) On this website i have an oracle database with a USERS tables that will store the logins and passwords of users from mysite.com I have a few questions : How should i store passwords,encryption of course, but which ? What should be the pro...

Can MySQL (Windows) do SHA-256 and HMAC hashing?

Long time reader, first time poster. And I start with quite a cryptic one! What I'm seeking to do is encrypt a string with the SHA-256 algorithm, and hash it with a key. I discovered someone had done some excellent work in creating an algorithm for "normal" SHA-2 encryption as a stored function at: http://blog.darkrainfall.org/sha-256-...

RSA private key encryption

Is there any way to perform private key encryption in C#? I know about the standard RSACryptoServiceProvider in System.Security.Cryptography, but these classes provide only public key encryption and private key decryption. Also, they provide digital signature functionality, which uses internally private key encryption, but there are not...

Decrypting EFS encrypted files

I have a number of files that were encrypted using EFS on my old Windows XP installation. I installed Windows 7 and now I can't access these files. You can read about the whole embarrassing situation here. The good news is that I have keys that will allow the files to be decrypted. I know this because I used EFS data recovery and it ...