Yeah, I just tried it and it compiles, but didn't work as expected.
It does seem attempt to do a match, but doesn't seem to be time related. If I set the config to this:
AuthMySQLUserCondition "timerow > '%t'"
Anything but a "0" in the "timerow" will match the above > match.
So I don't know what is being put in the %t from the code you mentioned. Could it be a case of comparing different types of data?
Or maybe it is the way I am using the code. Here is the code I put in based on the code you mentioned:
Code:
******* SNIP *******
static char * format_the_time(request_rec * r, char ** parm);
******* SNIP *******
typedef struct { /* User formatting patterns */
char pattern; /* Pattern to match */
char * (*func)(request_rec * r, char ** parm);
} format;
format formats[] = {{'h', format_remote_host},
{'a', format_remote_ip},
{'t', format_the_time},
******* SNIP *******
static char * format_the_time(request_rec * r, char ** parm) {
return ctime(&r->request_time);
}
******* SNIP *******