encryption

how are pgp keys formatted?

i want to write a program in python to simply read pgp keys. however, i cant seem to find any documentation describing how pgp keys are formatted. i dont want to be searching through the source code of open pgp to look for source code that i wont be able to understand. say i open a public key, remove the top "-----BEGIN PGP PUBLIC KEY ...

HTTP Packets, Whats Happening?

Hi there. basically, i was wiresharking packets on my PS3 while viewing Motorstorm Leaderboards. The leaderboards are sent to my ps3 in XML format but only after i have been authorised. So can someone please tell me what is happening between these three packets and how i could replicate it in a browser? Packet 1 From my PS3 to Sony Serv...

Using Ajax and jQuery to login a user through a PHP-script, is it secure?

Hi there, quick question, is it secure to use the jQuery.post function in jQuery to pass a users login information to a PHP script? Im thinking about using a piece of code like this: $("#login_form").submit(function() { var unameval = $("#username").val(); var pwordval = $("#password").val(); $.post("backend.php", { username: una...

using a key to rearrange string

Using Python I want to randomly rearrange sections of a string based on a given key. I also want to restore the original string with the same key: def rearrange(key, data): pass def restore(key, rearranged_data): pass Efficiency is not important. Any ideas? Edit: can assume key is hashable, but may be multiple types defin...

Java to/from C++ socket communication, DataInputStream and eof, binary, encryption

I'm trying to have Java server and C++ clients communicate over TCP under the following conditions: text mode, and binary/encrypted mode. My problem is over the eof indicator for end of stream that DataInputStream's read(byte []) uses to return with -1. If I send binary data, what's to prevent a random byte sequence happening to repres...

Keeping encrypted data in memory

I'm working with a listview control which saves the data using AES encryption to a file. I need to keep the data of every item in listview in std::list class of std::string. should I just keep the data encrypted in std::list and decrypt to a local variable when its needed? or is it enough to keep it encrypted in file only? ...

php encrypt and decrypt

can anyone tell me how to encrypt and decrypt a URL string ? I want to encrypt a hyperlink ... ...

How best to encrypt/decrypt SQL Server data to prevent even developers from seeing it?

Here's an interesting problem, and I'm looking for a pattern that will keep it all workable. I am building a smart-client app for a school system. It will contain information about students including their report cards, sick days, and so forth. it will generate student-level reports, including their report cards, each rich with very p...

Is it advisable to store a hashed password in a cookie?

I want user's to be able to select a "remember me" box on my website so they need not log in each time they come. So, I need to store a unique ID in a cookie to identify them. Is it safe to hash their password with sha512 and a long salt in PHP and store that value in the cookie? If the cookie was stolen, would their password be at risk?...

Is there a way to alter a public key in a way that the decryption can still be done with the private key after some alteration?

In an asymetric encryption scheme, I was wondering if it's possible to achieve the following: Bob sends to Alice his public key Alice alters Bob's public key and encrypt some document with it Alice sends the encrypted document to Bob Bob retrieve the document but can't decrypt it with his private key Later, Alice sends some additional ...

is there any good method to encrypt the C# desktop application

Possible Duplicate: Protect .NET code from reverse engineering? we just develop a application with C# winforms, is there any good encryption method to help us prevent from piracy ? I saw some software may need hardware support to protect their software, how to implement that ? Thanks in advance ! ...

Blackberry encrypt+persist data.

Hi all, My system enables users to save their work as a draft. I'd like to encrypt the data before I persist it. I was working on this - AESKey k = new AESKey(); AESEncryptorEngine a = new AESEncryptorEngine(k); a.encrypt(byte[] data_input, int input_offset, byte[] data_output, byte[] output_offset); I however need to persist an obje...

Get crypt() Blowfish results in PHP 5.3 identical to those generated by PHP 5.2

Is there a way in PHP 5.3 to get crypt() blowfish (salt starting with $2a$) results identical to those generated by PHP 5.2? In 5.3, Zend implements all encryption algorithms internally, thus producing different results. Also, in 5.3, blowfish needs a cost parameter. Basically, is there a way to call whatever system mechanisms were used...

getOutputSize constancy?

I need to encrypt and send data over TCP (from a few 100 bytes to a few 100 megabytes per message) in chunks from Java to a C++ program, and need to send the size of the data ahead of time so the recipient knows when to stop reading the current message and process it, then wait for the next message (the connection stays open so there's n...

Does a hash salt have any other use than to prevent rainbow table attacks?

I have heard that the only purpose of a salt is to prevent rainbow table attacks, but surely it must have more value than this? Would it not prevent a dictionary-based attack too? And what about brute-forcing, would a salt be of any use there? And could you explain why, please? Second, suppose I had an algorithm that took the microtime,...

Encrypting configuration information using protected configuration provider

When using a protected configuration provider to encrypt configuration information in a app config file, what encryption is used? What alogorithm and key is used to encrypt and decrypt the information? Update Ok, i've read the links provided by Sani Huttunen and read these here and here. So the RSAProtectedConfigurationProvider uses...

How display encrypted image using BitmapImage

I'm using BitmapImage as Source to an Image control in WPF. BitmapImage bi = new BitmapImage(); bi.BeginInit(); bi.CacheOption = BitmapCacheOption.OnLoad; bi.CreateOptions = BitmapCreateOptions.IgnoreImageCache; bi.UriSource = new Uri(strFilePath); bi.EndInit(); return bi; Now I've encrypted this image and planning to use this encrypt...

How to encode a value in PKCS7 with Java?

Hi, I would like to use PKCS7 encryption to encode a value together with Java and Java Servlet. Is there any available library and references to do the encryption? Any sample or tutorial that I could follow? Thank you. ...

iPhone In app purchases and Encryption export restrictions

When an application is being submitted to the Apple App store, I need to choose whether the app implements cryptography or not. My application itself does not use any cryptography, BUT it has In app purchase feature, i.e. the users can download additional paid content. I still didn't drill much into the in app purchase details, but I...

How secure is encryption in Access 2007?

How secure is encryption in Access 2007? ...