[MGNLUI-4431] Password field lose value after re-opening of a dialog Created: 14/May/18  Updated: 30/Jan/20  Resolved: 22/Oct/19

Status: Closed
Project: Magnolia UI
Component/s: None
Affects Version/s: 5.6.5
Fix Version/s: 5.5.16, 5.6.12, 5.7.6, 6.1.3, 6.2

Type: Bug Priority: Major
Reporter: David Caviedes Marquez Assignee: Dai Ha
Resolution: Fixed Votes: 0
Labels: form, password-manager, transformer
Remaining Estimate: 0d
Time Spent: 3d 1h
Original Estimate: Not Specified
Environment:

7 PRO 64 bits


Attachments: PNG File Screenshot 2019-09-30 at 10.01.24.png     PNG File after.png     PNG File before.png    
Issue Links:
Relates
causality
relation
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:
Epic Link: Support
Sprint: Declarative REST 6, Declarative REST 7, Declarative REST 8, Declarative REST 9
Story Points: 3

 Description   

Steps to reproduce:

  1. Open dialog and fill the password field
  2. Save dialog
  3. Check password value in JCR Browser - it is in there.
  4. Open the dialog again (the password field appears empty) but don´t modify password field
  5. Save dialog
  6. Check password value in JCR Browser - the value is empty! (Using BCrypt class there is generated new hash value corresponding to empty string!)

Tested with transformer classes: 

  • info.magnolia.ui.form.field.transformer.basic.BasicTransformer
  • and also BCrypt class: info.magnolia.ui.form.field.transformer.basic.BCryptTransformer
    • with BCrypt class the value is not empty but the hashed value is changed and corresponds to empty string
    • point 3: 
    • point 6: 


 Comments   
Comment by Ervin Vystup [ 17/May/18 ]

Workaround
Use custom save dialog action for dialogs where the password field is used.
Examples:  SaveUserProfileDialogAction.java and SaveUserDialogAction.java

Comment by Thomas Comiotto [ 27/Sep/18 ]

This is caused by the following line that has been added in commit 632a3efa6a9 for no obvious reason (PasswordFields.java).

180: newDataSource.setValue("");

Does anybody know why the workarounds in SaveUserProfileDialogAction.java and SaveUseAction.java were done instead of fixing the password field?

Comment by Milan Divilek [ 30/Sep/19 ]

Reopen:
Unfortunately fix for this issue cause problem with login form in "Cache Tools - Browser" and "About Magnolia - Report an issue" subapps
Submitting login form fails with validation error "This field is required" even when all fields are properly filled

Tested and reproduced on 5.5.x, 5.7.x, 6.1.x and 6.2.x

Comment by Dai Ha [ 16/Oct/19 ]

Reopen because SaveUserDialogAction need to be corrected.

Generated at Mon Feb 12 09:16:32 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.