Hi, I am looking for how to send email before expiration of account. The value used for the expiration in radius is character format. So, I would like to know how to compare the expiration data and send email accordingly. Thanks in advance. John.
If you're asking me, I wouldn't mess with freeradius. Maybe the better idea is to create a small cron script which can read the database and send email according to the date and the time diff you want (1, 2, 3 etc days before the expiration) On 12/6/2011 3:54 AM, john decot wrote:
Hi,
I am looking for how to send email before expiration of account. The value used for the expiration in radius is character format. So, I would like to know how to compare the expiration data and send email accordingly.
Thanks in advance.
John.
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Thanks for the reply. I am also trying same but couldn't compare with the field on the database as Expiration attribute use character value. I wish someone give me any idea on comparing those parameter inside database. ________________________________ From: Marinko Tarlać <mangia81@gmail.com> To: freeradius-users@lists.freeradius.org Sent: Tuesday, December 6, 2011 1:33 PM Subject: Re: Expiration email If you're asking me, I wouldn't mess with freeradius. Maybe the better idea is to create a small cron script which can read the database and send email according to the date and the time diff you want (1, 2, 3 etc days before the expiration) On 12/6/2011 3:54 AM, john decot wrote: Hi,
I am looking for how to send email before expiration of account. The value used for the expiration in radius is character format. So, I would like to know how to compare the expiration data and send email accordingly.
Thanks in advance.
John.
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
On Tue, Dec 6, 2011 at 7:22 PM, john decot <johndecot@yahoo.com> wrote:
Thanks for the reply. I am also trying same but couldn't compare with the field on the database as Expiration attribute use character value. I wish someone give me any idea on comparing those parameter inside database.
Several ways I can think of (completely untested): (1) Use http://dev.mysql.com/doc/refman/5.5/en/date-and-time-functions.html#function... (or whatever equivalent function in your db) to convert the column to date before comparison (2) Pick a time to alert the user (e.g. ONE WEEK before expiration), then use whatever programming language of your choice (e.g. php) to convert the date into the format used in expiration attribute (e.g. using date_format). Then you only need to compare for exact string match. -- Fajar
thanks Fajar, Let me give a try. ________________________________ From: Fajar A. Nugraha <list@fajar.net> To: john decot <johndecot@yahoo.com>; FreeRadius users mailing list <freeradius-users@lists.freeradius.org> Sent: Tuesday, December 6, 2011 6:38 PM Subject: Re: Expiration email On Tue, Dec 6, 2011 at 7:22 PM, john decot <johndecot@yahoo.com> wrote:
Thanks for the reply. I am also trying same but couldn't compare with the field on the database as Expiration attribute use character value. I wish someone give me any idea on comparing those parameter inside database.
Several ways I can think of (completely untested): (1) Use http://dev.mysql.com/doc/refman/5.5/en/date-and-time-functions.html#function... (or whatever equivalent function in your db) to convert the column to date before comparison (2) Pick a time to alert the user (e.g. ONE WEEK before expiration), then use whatever programming language of your choice (e.g. php) to convert the date into the format used in expiration attribute (e.g. using date_format). Then you only need to compare for exact string match. -- Fajar
Everything can be found via Google in less than 1 minute. On 12/6/2011 1:22 PM, john decot wrote:
Thanks for the reply. I am also trying same but couldn't compare with the field on the database as Expiration attribute use character value. I wish someone give me any idea on comparing those parameter inside database.
------------------------------------------------------------------------ *From:* Marinko Tarlać <mangia81@gmail.com> *To:* freeradius-users@lists.freeradius.org *Sent:* Tuesday, December 6, 2011 1:33 PM *Subject:* Re: Expiration email
If you're asking me, I wouldn't mess with freeradius.
Maybe the better idea is to create a small cron script which can read the database and send email according to the date and the time diff you want (1, 2, 3 etc days before the expiration)
On 12/6/2011 3:54 AM, john decot wrote:
Hi,
I am looking for how to send email before expiration of account. The value used for the expiration in radius is character format. So, I would like to know how to compare the expiration data and send email accordingly.
Thanks in advance.
John.
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
participants (3)
-
Fajar A. Nugraha -
john decot -
Marinko Tarlać