dongxuan8227
2010-10-27 23:46
浏览 1.1k

我应该如何存储AES加密密钥?

I run a DV 3.5 server on MediaTemple with Linux CentOS 5, php and mysql DB and am trying to encrypt phone records with AES.

I came across what seems to be good script as PHPAES

but I am not sure of the following:

  1. Where do I actually store the AES Encryption key used to encrypt and decrypt the phone number?

  2. How do I call on the AES encryption key when a user submits their data via form and stores into our MySQL database?

  3. When I want to descrypt that information for our internal customer service agents - how do they in turn call on the AES key?

I realize this is probably very simple but please don't insult. I am trying to learn best practice for how to move forward with any type of encryption whatsoever. Something (to this point) we have not had need for.

图片转代码服务由CSDN问答提供 功能建议

我使用Linux CentOS 5,php和mysql DB在MediaTemple上运行DV 3.5服务器,我正在尝试加密电话记录 用AES。

我偶然发现了 PHPAES 。 p>

但我不确定以下内容:

  1. 我在哪里实际存储用于加密的AES 加密密钥 和 解密电话号码?

  2. 当用户提交数据 via表格并存储到我们的MySQL database中时,如何调用AES encryption key?

  3. 当我想为我们的内部客户服务代理解密该信息时 - 他们如何依次调用AES密钥?

    我意识到这可能很简单,但请不要侮辱。 我正在尝试学习如何推进任何类型的加密的最佳实践。 我们没有必要的东西(到目前为止)。

  • 写回答
  • 好问题 提建议
  • 关注问题
  • 收藏
  • 邀请回答

2条回答 默认 最新

  • dtz30833 2010-11-03 16:08
    已采纳

    I actually ended up going this route:

    I encrypt the initial data with a salted hash which is stored in the database itself (and is unique to every record stored). I then take that 256bit AES encrypted string and run it through RSA encryption with my public key which sits server side.

    in order to decrypt, I have to upload a temporary file with my private key and retrieve the necessary data.

    quite secure in my opinion.

    评论
    解决 无用
    打赏 举报
  • 查看更多回答(1条)

相关推荐 更多相似问题