当前位置:网站首页>What encryption algorithm is used for the master password of odoo database?
What encryption algorithm is used for the master password of odoo database?
2022-07-04 15:29:00 【weixin_ forty-three million four hundred and twenty-five thousa】
The default encryption algorithm is pbkdf2_sha512, The result obtained by adding salt iterations to the hash algorithm is used as the algorithm of password . Its basic principle is through a pseudo-random function ( for example HMAC function ), Take plaintext and a salt value as input parameters , Then repeat the operation , And finally generate the key . If the number of repetitions is large enough , The cost of cracking will become very high . The addition of salt value will also increase “ Rainbow watch ” The difficulty of the attack .
Let's look at a password structure obtained by this encryption algorithm :
$pbkdf2-sha512 25000 25000 25000ztkbw5jT.l8LwThHKKX03g$EFv2mH5uUh6VEZi4mmvzphsDnQdI1ufTw6JxppxXPfRIUj5JBK9N/kd.5NgiCCylwgiyUqCk0CiugHdYQQXNKA
The password goes through $ Symbols are separated into 4 part , The first part is the name of the calculation algorithm , The second is the number of iterations , The third part is the salt value , The fourth part is hash value .
Activate odoo A virtual environment , Run on the command line python, The plaintext password can be ’admin’ To encrypt , You can also ’admin’ Replace it with any plaintext password you want to use .
from passlib.context import CryptContext
print(CryptContext(['pbkdf2_sha512','plaintext'],deprecated=['plaintext'],).encrypt('admin'))
Available :
$pbkdf2-sha512$25000$ztkbw5jT.l8LwThHKKX03g$EFv2mH5uUh6VEZi4mmvzphsDnQdI1ufTw6JxppxXPfRIUj5JBK9N/kd.5NgiCCylwgiyUqCk0CiugHdYQQXNKA
Put it in odoo.conf in ,
admin_passwd=$pbkdf2-sha512$25000$ztkbw5jT.l8LwThHKKX03g$EFv2mH5uUh6VEZi4mmvzphsDnQdI1ufTw6JxppxXPfRIUj5JBK9N/kd.5NgiCCylwgiyUqCk0CiugHdYQQXNKA
One day I forgot the database master password , You can use the above method to generate a new encrypted password , take odoo.conf Medium admin_passwd Just replace it .
边栏推荐
- How to rapidly deploy application software under SaaS
- LeetCode 1184. Distance between bus stops -- vector clockwise and counterclockwise
- Summer Review, we must avoid stepping on these holes!
- 一篇文章搞懂Go语言中的Context
- . Net applications consider x64 generation
- Techsmith Camtasia Studio 2022.0.2屏幕录制软件
- When synchronized encounters this thing, there is a big hole, pay attention!
- 2022年九大CIO趨勢和優先事項
- 产品好不好,谁说了算?Sonar提出分析的性能指标,帮助您轻松判断产品性能及表现
- CentOS 6.3 下 PHP编译安装JSON模块报错解决
猜你喜欢
Redis sentinel mode realizes one master, two slave and three Sentinels
Nine CIO trends and priorities in 2022
Functional interface, method reference, list collection sorting gadget implemented by lambda
Who the final say whether the product is good or not? Sonar puts forward performance indicators for analysis to help you easily judge product performance and performance
产品好不好,谁说了算?Sonar提出分析的性能指标,帮助您轻松判断产品性能及表现
Ffmpeg Visual Studio development (IV): audio decoding
Luo Gu - some interesting questions 2
Understand the context in go language in an article
MySQL学习笔记——数据类型(2)
這幾年爆火的智能物聯網(AIoT),到底前景如何?
随机推荐
进制乱炖
直播预告 | PostgreSQL 内核解读系列第二讲:PostgreSQL 体系结构
MySQL index optimization
[local differential privacy and random response code implementation] differential privacy code implementation series (13)
Temperature control system based on max31865
Unity script introduction day01
Dialogue with ye Yanxiu, senior consultant of Longzhi and atlassian certification expert: where should Chinese users go when atlassian products enter the post server era?
Unity脚本生命周期 Day02
2022年九大CIO趋势和优先事项
谈SaaS下如何迅速部署应用软件
输入宽度!
Shell 编程基础
JS tile data lookup leaf node
MySQL~MySQL给已有的数据表添加自增ID
Redis publish and subscribe
Logstash~Logstash配置(logstash.yml)详解
数据湖治理:优势、挑战和入门
Understand the context in go language in an article
左右对齐!
Unity script API - transform transform