Skip to content

dsidm and cockpit ui crashes when account policy is enabled (float() argument must be a string or a number, not 'NoneType') #6288

Closed
@navidys

Description

@navidys

Issue Description
Followed instruction on RHDS-11 documentation in order to setup time-based account policy using CoS.
after setup cockpit UI crashes and also following dsidm command showing error:

dsidm  -b dc=MTTS mttsldp01li account entry-status cn=user01,ou=people,dc=MTTS
Error: float() argument must be a string or a number, not 'NoneType'

Package Version and Platform:

  • Platform: EL8
  • Package and version: 389-ds-base-1.4.3
  • Browser: chrome

Steps to Reproduce
1- Enable account policy plugin and do configuration:

# dsconf -D "cn=Directory Manager" <instance> plugin account-policy enable

# dsconf -D "cn=Directory Manager" <instance>  plugin account-policy set --config-entry="cn=config,cn=Account Policy Plugin,cn=plugins,cn=config"

# dsconf -D "cn=Directory Manager" <instance> plugin account-policy config-entry set "cn=config,cn=Account Policy Plugin,cn=plugins,cn=config"  --alt-state-attr createTimestamp --spec-attr acctPolicySubentry --limit-attr accountInactivityLimit --always-record-login yes --state-attr lastLoginTime

# dsctl <instance> restart

2- create account inactivity policy

ldapadd -D "cn=Directory Manager" -W -H <ldaps instance URI> -x	  
dn: cn=Account Inactivation Policy,dc=MTTS
objectClass: top
objectClass: ldapsubentry
objectClass: extensibleObject
objectClass: accountpolicy
accountInactivityLimit: 20
cn: Account Inactivation Policy

dn: cn=TemplateCoS,dc=MTTS
objectClass: top
objectClass: ldapsubentry
objectClass: extensibleObject
objectClass: cosTemplate
acctPolicySubentry: cn=Account Inactivation Policy,dc=MTTS

dn: cn=DefinitionCoS,ou=People,dc=MTTS
objectClass: top
objectClass: ldapsubentry
objectclass: cosSuperDefinition
objectclass: cosPointerDefinition
cosTemplateDn: cn=TemplateCoS,dc=MTTS
cosAttribute: acctPolicySubentry default operational-default

3- create new user account

# dsidm -b dc=MTTS <instance> user create
....

4- get user entry status and dsidm will crash which will lead to cockpit-ui crash as well since its using dsidm cmd

dsidm  -b dc=MTTS <instance> account entry-status cn=user02,ou=people,dc=MTTS
Error: float() argument must be a string or a number, not 'NoneType'

Metadata

Metadata

Assignees

No one assigned

    Labels

    CLICLI toolsbugSomething isn't workingneeds triageThe issue will be triaged during scrum

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions