Connect to the Purdue Home Page

Purdue University

Identity and Access Management

DBM Times

The I2A2 DBMs record times in an extension of the UNIX seconds since the epoch format.

The extended format includes an integer representing the seconds since the UNIX epoch on January 1, 1970, optionally followed by a period and an integer serial number which is advanced by a DBM each time it uses the same seconds since the epoch value.

Format

A DBM time is represented as one or two decimal integers. The first integer, always present, is the number of seconds since the UNIX epoch.

If a DBM issues more than one time stamp in a second (that's common, because the DBMs are very fast.), it will add a period, followed by a second decimal integer. The second integer is a serial number that starts at 0 (zero).

Example

Here is an example DBM Time

983452209.503

It represents the five hundred and third time used by a DBM that is 983452209 seconds past the UNIX epoch. The seconds since the epoch value converts to:

Thursday March 1, 2001 at 08:10:09 a.m.

If the DBM has used no other time stamp in the same second, the previous time would have been represented as:

983452209

Converting DBM Times

DBM times are described in the following structure, found in puid_types.h (That header file is included in libpuidX):

typedef struct {
    time_t pt_epoch; /* seconds since the epoch */
    int pt_tmser;    /* same epoch seconds serial */
} puidtm_t;        
        

The pt_epoch value may be supplied as the argument to the UNIX ctime(3) function to obtain a formatted date and time of this form:

Thu Mar 1 08:10:09 2001

Feedback | Contact Purdue
Maintained by: IAMO Team

Purdue University, West Lafayette, IN 47907, (765) 494-4600
© 2010 - 2013 Purdue University | An equal access/equal opportunity university | Copyright Complaints
If you have trouble accessing this page because of a disability, please contact the CSC at itap@purdue.edu or (765) 494-4000.