Where is the prefilled user name on KDE login screen stored - linux

We are heavily using VirtualBox on our developer workstations. Since we share the images with other developers quite often, I have tried to automate this process as much as possible (cleaning up ap-get cache, removing tmp and log files...). We are using Ubuntu 11.10 with KDE 4.7.4, by the way.
Now I have stumbled over one little annoyance. At the login screen there is a user name prefilled and I could not figure out where this is stored. The problem is, if people get a VirtualBox image and don't realise that the pre-filled user name is not their own and enter their password a couple of time, they lock the said user on our LDAP.
Any idea where is this user name is stored, so I could remove it..?

By default, the login screen (KDM) will preselect the the last logged-in user and I'm not sure where it gets this information. However, you can configure KDM to always preselect the same user in /etc/kde4/kdm/kdmrc:
# Greeter config for all displays
[X-*-Greeter]
...
# Specify, if/which user should be preselected for log in.
# "None" - do not preselect any user
# "Previous" - the user which successfully logged in last time
# "Default" - the user specified in the DefaultUser option
# Default is None
PreselectUser=Default
# The user to preselect if PreselectUser=Default.
# Default is ""
DefaultUser=johndoe
...
Of course, you can set PreselectUser=None if you don't want to select any user.

On OpenSUSE 12.2 it is the /var/lib/kdm/kdmsts
# cat /var/lib/kdm/kdmsts
[PrevUser]
:0=user1
:1=user2
:2=user1

Related

modify user's UID not updating

need to modify UID of a specific user so created:
#change UID of bob from 555 to 1555
user 'bob' do
action :modify
uid 1555
end
After the chef-client runs with no errors
Recipe: bob-uid-change::default
* user[bob] action modify (up to date)
The user's ID do not change on /etc/passwd
Am I missing something?
Thanks!
Modify will not work if the user (bob) is currently logged in and using the system, i.e. if there are any active processes for bob.
However, if I remember correctly, chef will bomb out if it can't modify the user due to an active process in their name... instead of silently moving on without updating the user as is with this case. It's worth a check to make sure you aren't logged in as bob anywhere first though

Superuser Can't Change User Profile

Despite being a Super User (Joomla 3.4), each time I try to modify a user's profile, e.g., edit their name or assign them to a different group, I get this message:
The passwords you entered do not match. Please enter your desired password in the password field and confirm your entry by entering it in the confirm password field.
I am not entering a password. It almost looks like Joomla (or my Mac) is autofilling the first password entry and wants me to fill in the confirming password entry.
Please advise.
delete the auto-filled password and save - this is a browser thing

Disable Default Password Policy with portal-ext.properties

So i want to disable the required password change for fist time users.
I am running this local, to test this out until it works, as i want it.
I have made an portal-ext file that contains the following:
company.security.auth.type=screenName
users.screen.name.allow.numeric=true
terms.of.use.required=false
users.reminder.queries.enabled=false
passwords.default.policy.changeable=true
passwords.default.policy.change.required=false
users.reminder.queries.custom.question.enabled=false
users.last.name.required=false
users.email.address.required=false
passwords.toolkit=com.liferay.portal.security.pwd.RegExpToolkit
passwords.regexptoolkit.charset=0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghilmnopqrstuv
passwords.regexptoolkit.length=8
passwords.regexptoolkit.pattern=.+
As you can see, i have already set the passwords.default.policy.change.required to false.
But when i login with a first time user, it still shows the "change password" screen, which it should not.
It NEEDS to be done from the portal-ext file, and not the control panel, since this file is going on multiply servers,
so its disabled on all. And future servers as well.
Anyone have an idea whats wrong, or what I'm needing ?
Thanks in advance
when you add the property
passwords.default.policy.changeable=true
It means allow user to change his password. On other hand when you set the property,
passwords.default.policy.change.required=false
It implies its mandatory for the user to change the password. Here, you are setting it false. So we should not get 'Change password' screen.
I would suggest try to remove changeable property from the portal-ext.property file.
passwords.default.policy.changeable=true
A further look at the liferay forum, i found a post about this, where a liferay staff posted this answer:
Unfortunately the default password policy is not something you can
configure in portal(-ext).properties so there's no way to disable it
that way.
It's therefore impossible to get the result I'm looking for.
Source
Blockquote
So i want to disable the required password change for fist time users. I am running this local, to test this out until it works, as i want it.
Blockquote
If you want to diseable change required for users password, just use this portal propertie:
passwords.default.policy.change.required=false
#Patrick R This is the portal-ext i use . See the screenshots of new user login in.Im not sure whether this will solve your issue or not.Please cross the check the properties.
#jdbc.default.jndi.name=jdbc/LiferayPool
jdbc.default.driverClassName=com.mysql.jdbc.Driver
jdbc.default.url=jdbc:mysql://localhost/lportal?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false
jdbc.default.username=root
jdbc.default.password=root
soas.database.name=soasdb
soas.database.username=root
soas.database.password=root
soas.database.hostname=localhost
soas.database.connection=jdbc:mysql://localhost/soasdb?user=root&password=root
soas.servicepartner.name=localhost
json.service.auth.token.hosts.allowed=127.0.0.1
json.service.auth.token.enabled=false
jsonws.web.service.public.methods=*
jsonws.servlet.hosts.allowed=127.0.0.1
users.screen.name.validator=com.liferay.portal.security.auth.LiberalScreenNameValidator
ldap.base.provider.url= ldap://localhost:389
ldap.base.dn= dc=soas,dc=schoox
ldap.security.principal= cn=admin
ldap.security.credentials= blahblah
auth.pipeline.pre=com.liferay.portal.security.auth.LDAPAuth
ldap.auth.enabled=true
ldap.auth.required=false
ldap.password.policy.enabled=true
ldap.users.dn= dc=soas,dc=schoox
ldap.groups.dn= dc=soas,dc=schoox
ldap.import.enabled=true
ldap.import.interval=1
ldap.import.on.startup=true
ldap.import.method=group
ldap.import.group.search.filter.enabled=true
ldap.import.user.password.enabled=false
ldap.import.user.password.autogenerated=false
ldap.import.user.password.default=userPassword
ldap.user.mappings=screenName=uid\npassword=userPassword\nemailAddress=mail\nfirstName=givenName\nlastName=sn
#ldap.user.mappings=screenName=cn\npassword=userPassword\nemailAddress=mail\nfirstName=cn\nlastName=sn
#ldap.user.mappings=screenName=displayName\npassword=userPassword\nemailAddress=mail\nfirstName=givenName\nlastName=sn
ldap.group.mappings=groupName=cn\ndescription=description\nuser=member
ldap.import.user.search.filter=(objectClass=inetOrgPerson)
ldap.import.group.search.filter=(objectClass=groupOfEntries)
ldap.auth.search.filter=(uid=#screen_name#)
axis.servlet.hosts.allowed=
axis.servlet.https.required=false
company.security.auth.type=screenName
search.container.show.pagination.top=false
setup.wizard.enabled=false
When a new user login
Terms and condition
Password Reminder
Successfull login
I agree with Olaf Kock. I'm currently working on a Liferay DXP 7.2 upgrade from 6.2 and I'm facing the same issue of having Change Password screen on first-time user login through Kerberos SSO.
I went through the addUserWithWorkflow method of Liferay codebase in UserLocalServiceImpl and I've also verified the database table for handling the Password Policy which has these columns for configuring Password Changeable and Change Required settings. During addUser for the first-time, passwordReset column in the Liferay table - User_ is set as 1 (true) if the columns in Password Policy is set to 1 (true). This is the reason why we see Change Password prompt after user login.
I understood that the only way to change this configuration through portal-ext.properties is when the Liferay is setup for the first time before the server startup otherwise, a DB patch has to be applied in the Liferay table - PasswordPolicy to set 0 (false) for the below columns.
changeable and changeRequired

Changing my account to username in opencart

I have this small problem i am using open cart v 2.0.1.1 and when the user is logged in it shows my account with the drop down. I want to display the username of that particular user instead of " my account" can anyone help me with this problem?
in case of you don't know how start
(1) you will need to read this post How to become an open cart guru
(2) steps
you will need to pass the name of the customer in some variable to the template file by adding it to $data array in catalog/controller/common/header.php # class ControllerCommonHeader # function index
in the template file, change the part that checks whether the user is logged in or not, and add the passed customer name or the old header My Account depending on the branch

Cucumber: Is it possible for a step to detect tags?

I am in the midst of writing a test suite for a password management page. For the scenarios, the majority should not actually change the password, but some do. I have used the tag #changePassword so that I can optionally run those scenarios or not.
The problem I run into is trying not to write duplicate steps if possible.
Simplified sample scenarios:
#changePassword
Scenario: successful change
Given the Manage Password page is loaded
And a new password is generated
When the old password is entered
And the new password is entered
And the confirm password is entered
And the OK button is clicked
Then the password has changed
Scenario: failed change (missing confirm)
Given the Manage Password page is loaded
And a new password is generated
When the old password is entered
And the new password is entered
And the OK button is clicked
Then the password change fails
The majority of the steps are identical between the two versions, the main variance that I am concerned with is the And a new password is generated step. In the first scenario, I want the new password to be saved as the user's password. In the second scenario I want the new password discarded at the end.
Something like: (psuedo-code)
And /^a new password is generated$/ do
old password = user's password
new password = generate random new password
confirm password = new password
if tag #changePassword is present
user's password is set as the new password
end
end
Is there anyway to make this possible? I can write a second step like And a new password to be saved is generated or something, but for readability and for the non-tech savvy co-workers, using the same step is the better option. (I have found in the past using different phrases to describe similar processes, that to the user accomplishes the exact same thing, has caused confusion. Trying to avoid workplace confusion if possible.)
Side note: Using Cucumber with Ruby (with Watir), if that makes any difference (does it?)
It's an ugly solution, but can you use a tagged hook to set a variable and then an if statement in the method that saves/doesn't save based on the value of that variable?

Resources