开发者

How to make password file hashed with SHA1

The <passwordFile> element is used to specify a file which has a set of username and password pairs. The format of username and password i开发者_开发知识库n this file is ${username}=${password which has been hashed with SHA1}, with one line per user.

Examples

Suppose the password file is admins.properties, which is located in /home/locker. You want to create two users as Administrators:

  • one username is nlohchab, the password hashed with SHA1 is ThmbShxAtJepX80c2JY1FzOEmUk=
  • the other one is james, the password hashed with SHA1 is TfkgShslgJepX80c2JY1trwEskT=


  1. SHA is a hashing algorithm, you can't encrypt anything with it.
  2. your question is not programming-related and ServerFault.com is a better place for it.
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜