mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 18:36:30 +01:00 
			
		
		
		
	login is now configured in the ini file instead of being hardcoded
This commit is contained in:
		
							
								
								
									
										18
									
								
								generate-password.py
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								generate-password.py
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,18 @@ | ||||
| #!/usr/bin/python | ||||
|  | ||||
| import bcrypt # pip install bcrypt | ||||
| import getpass | ||||
|  | ||||
| password1 = getpass.getpass() | ||||
|  | ||||
| print('Repeat the same password:') | ||||
|  | ||||
| password2 = getpass.getpass() | ||||
|  | ||||
| if password1 == password2: | ||||
|     salt = bcrypt.gensalt() | ||||
|  | ||||
|     print('Generated hash:') | ||||
|     print(bcrypt.hashpw(password1, salt)) | ||||
| else: | ||||
|     print('Entered passwords are not identical!') | ||||
		Reference in New Issue
	
	Block a user