[Libreoffice] [REVIEW] fix for fdo#37628: pssword button is always disabled
Kohei Yoshida
kyoshida at novell.com
Mon Jul 25 22:37:32 PDT 2011
Hello Markus,
On Sun, 2011-07-24 at 20:22 +0200, Markus Mohrhard wrote:
> Hello Kohei, all,
>
> this is a possible patch for the problem that the button at
> File->Properties is always disabled even if you have a password
> protected file.
>
> The problem was that SID_PASSWORD, which saved the plain text
> password, is no longer used but we use SID_ENCRYPTIONDATA which saves
> the hash. I changed the code for this button so that it shares the
> implementation with the file save dialog.
Yup, the change looks fine to me, and the password change functionality
appears to work just fine for the open-document password.
There is one minor issue. The dialog that gets launched from the Change
Password button also contains the optional password input for modifying
document, and setting a new password there doesn't appear to change the
modify-document password. Not sure if this is worth fixing, or trivial
to fix...
> I haven't found a nice place for the method RequestPassword so I have
> decided to leave it in filedlghelper.[ch]xx . I'm open for any
> suggestions where this method should be located.
I think the place where you put it is just fine for me.
> This patch applies to 3.4, I haven't tested yet with master since
> master has several code changes in the password related code.
Indeed. I tried to git am your patch on master and it failed to apply.
I wonder if this is a big change, or just a minor change enough to make
the patch not apply cleanly... I haven't looked too closely into it
yet.
Regards,
Kohei
--
Kohei Yoshida, LibreOffice hacker, Calc
<kyoshida at novell.com>
More information about the LibreOffice
mailing list