EntryIsLocked is only updated when the screen is turned off. So if you update your password type, it won't notice until you lock the screen. A bug, but not one that has affected anyone yet.
Thinking about what you'll need to implement this, it's probably better for you to query AccountsService's PasswordMode property for the current user -- if it is 2, they are in swipe mode, 0 for having set a password of some sort. And also the PasswordDisplayHint property on the com.ubuntu.AccountsService.SecurityPrivacy interface for the current user in AccountsService -- this will tell you whether it's a passcode (1) or passphrase (0).
Then you'd need to use PAM to actually authenticate.
Looking back at the description of this bug... Can a user do anything super awful in Terminal that they can't do using the phone in general? Anything that requires sudo will require the user's passcode already.
EntryIsLocked is only updated when the screen is turned off. So if you update your password type, it won't notice until you lock the screen. A bug, but not one that has affected anyone yet.
Thinking about what you'll need to implement this, it's probably better for you to query AccountsService's PasswordMode property for the current user -- if it is 2, they are in swipe mode, 0 for having set a password of some sort. And also the PasswordDisplayHint property on the com.ubuntu. AccountsService .SecurityPrivac y interface for the current user in AccountsService -- this will tell you whether it's a passcode (1) or passphrase (0).
Then you'd need to use PAM to actually authenticate.
Looking back at the description of this bug... Can a user do anything super awful in Terminal that they can't do using the phone in general? Anything that requires sudo will require the user's passcode already.