Question

I'm developing a web app and I have to encrypt data with RSA. I'm using FuelPHP and MySQL. My problem is that when I want to insert encrypted value, it doesn't works, the value is null.

For example, when I want to insert

"Š@žÊ~±ðÞ” ¯šÝ²à6°ÔökáÒïX´nÜ t|÷"ŒIñˆÃæ\{·"/8QzÑ6©Õîýízâ®ï Û»·Åe“ópÓ*ˆeÍ,¸XK’‡HR")DO@þÞœ¬±1õ0ð>‚ûÜÑ ;´šSxБÓýäƒ6ÈJ"

which is Guillaume encrypted with an RSA private key. The inserted value is null.

The type of my attribute is varchar(128), I also tried varchar(256) but it doesn't works.

Was it helpful?

Solution

You need to use Binary data type such as BLOB for storing this kind of data.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top