/*
- * Copyright 2000 by the Massachusetts Institute of Technology.
+ * Copyright 2000, 2001 by the Massachusetts Institute of Technology.
* All Rights Reserved.
*
* Export of this software from the United States of America may
* The following table contains an exponential scale that covers the
* lifetime values 128 to 191 inclusive (a total of 64 values).
* Values greater than 191 get interpreted the same as 191, but they
- * will never be generated by the functions in this file. The special
- * case of a lifetime byte of 255 gets interpreted as never expiring,
- * which corresponds to an expiration date of KRB_NEVERDATE, which
- * should be (-1).
+ * will never be generated by the functions in this file.
*
* The ratio is approximately 1.069144898 (actually exactly
* exp(log(67.5)/63), where 67.5 = 2592000/38400, and 259200 = 30
* days, and 38400 = 128*5 minutes. This allows a lifetime byte of
* 191 to correspond to a ticket life of exactly 30 days and a
- * lifetime byte of 191 to correspond to exactly 128*5 minutes, with
+ * lifetime byte of 128 to correspond to exactly 128*5 minutes, with
* the other values spread on an exponential curve fit in between
* them. This table should correspond exactly to the set of extended
* ticket lifetime values used by AFS and CMU.
};
#define MINFIXED 0x80
#define MAXFIXED (MINFIXED + NLIFETIMES - 1)
-#define NOEXPIRE 0xFF
#endif /* !SHORT_LIFETIME */
/*
if (life < 0 || life > 255) /* possibly sign botch in caller */
return start;
#ifndef SHORT_LIFETIME
- if (life == NOEXPIRE)
- return KRB_NEVERDATE;
if (life < MINFIXED)
return start + life * 5 * 60;
if (life > MAXFIXED)
if (dt <= 0)
return 0;
#ifndef SHORT_LIFETIME
- if (end == KRB_NEVERDATE)
- return NOEXPIRE;
if (dt < lifetimes[0])
return (dt + 5 * 60 - 1) / (5 * 60);
/* This depends on the array being ordered. */