Announcement

Collapse
No announcement yet.

Getting warned of upcoming password expiration

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [DESKTOP] Getting warned of upcoming password expiration

    Is there a desktop-friendly way (in 14.04) to be warned when one's password is about to expire? As far as I can tell the KDE session login is not even able to let me log in one last time and then force me to replace the password on the spot as it is done in some other operating system that shall remain nameless.

    #2
    Run KUser, select the user account and tab "Password Management"

    I set the time to expire to 99999 days, which is somewhat past my expected lifetime...
    Kubuntu 24.11 64bit under Kernel 6.11.0, Hp Pavilion, 6MB ram. Stay away from all things Google...

    Comment


      #3
      Originally posted by TWPonKubuntu View Post
      Run KUser, select the user account and tab "Password Management"

      I set the time to expire to 99999 days, which is somewhat past my expected lifetime...
      Password expiration isn't my choice, I have to live with it (and it's not that bad, as long as you get an advance warning, so you can start to think about the next one).

      Comment


        #4
        Depends on where the password is maintained as the notification needs to come from there. Only the machine that actually manages your password knows when it will expire.

        If it's on your local machine (and if you have access to sudo) you can change your password with a -w switch and specify the number of days before you're notified you need to change your password. If your password is maintained on a machine other than your own you're gonna need to bribe a sysadmin to help you
        we see things not as they are, but as we are.
        -- anais nin

        Comment


          #5
          Originally posted by wizard10000 View Post
          Depends on where the password is maintained as the notification needs to come from there. Only the machine that actually manages your password knows when it will expire.

          If it's on your local machine (and if you have access to sudo) you can change your password with a -w switch and specify the number of days before you're notified you need to change your password. If your password is maintained on a machine other than your own you're gonna need to bribe a sysadmin to help you
          The password is kept on my machine, and "chage -l {myid}" tells me how old it is:

          Code:
          ~/ >chage -l me
          Last password change                                    : May 29, 2016
          Password expires                                        : Aug 27, 2016
          Password inactive                                       : never
          Account expires                                         : never
          Minimum number of days between password change          : 0
          Maximum number of days between password change          : 90
          Number of days of warning before password expires       : 7
          But this isn't "desktop-friendly".

          Comment


            #6
            Originally posted by Ofnuts View Post
            ...But this isn't "desktop-friendly".
            No, it isn't

            I saw a couple of homegrown scripts that were an easy google away but all of them require read access to /etc/shadow, which can only be read by the root account. Only other way I can think of to do it would be to parse the output of 'chage -l', compare the expiration date to the current date and pop up a dialog or send an email if your password is about to expire - but I haven't found a script that does it that way and the task exceeds my own limited scripting capabilities. Perhaps someone else has an idea?
            we see things not as they are, but as we are.
            -- anais nin

            Comment


              #7
              Install kuser from Discover or by running sudo apt install kuser, it provides the exact functionality you are looking for.
              If you're sitting wondering,
              Which Batman is the best,
              There's only one true answer my friend,
              It's Adam Bloody West!

              Comment


                #8
                Installed it but it looks like an admin tool to manage users, and I didn't see how I can use it to be warned of an impending password expiration.

                Comment


                  #9
                  Select user -> Password Management -> Time before password expires to issue an expire warning
                  If you're sitting wondering,
                  Which Batman is the best,
                  There's only one true answer my friend,
                  It's Adam Bloody West!

                  Comment


                    #10
                    Originally posted by elijathegold View Post
                    Select user -> Password Management -> Time before password expires to issue an expire warning
                    This looks like it justs sets the value that "chage -l" displays... but what uses it?

                    Comment


                      #11
                      Oh I see, you mean when logging in. In that case, I would initially have a poke around in the notification / greeter settings and if nothing suitable is found, to script a solution as suggested by @wizard1000 in post #6

                      To be honest, if the setting exists in Plasma, it could be anywhere depending on how much the developers drunk while designing it.
                      If you're sitting wondering,
                      Which Batman is the best,
                      There's only one true answer my friend,
                      It's Adam Bloody West!

                      Comment


                        #12
                        OK, so script it is... Looks like Screen saver/Screen unlocked is a good notification candidate (I seldom login but often unlock...).

                        Comment

                        Working...
                        X