Forum Discussion

ge0ff73_32053's avatar
ge0ff73_32053
Icon for Nimbostratus rankNimbostratus
Apr 03, 2015
Solved

Trying to convert pwdLastSet to Day Month Year Time format

I'm trying to take session.ad.last.attr.pwdLastSet and convert it to a more user-friendly readable format. I'm very weak on both Active Directory as well as Tcl.   Here's what I have so far:   ...
  • kunjan_118660's avatar
    Apr 04, 2015

    The time expected in clock cmd is in epoch. But AD returns in "Windows NT time" format. For the conversion, can try the following:

    set clockFormat "[clock format [expr (($pwdLastSet_epoch / 10000000) - 11644473600)]]"