Re:Need help on Accounting Response

2008-12-18 Thread Do Nguyen Ha
Hi Ivan Kalik

thank you for your answer

as i explain, i read the man unlang times but cannot figure out how to use it 
and Alan asked me the specific case
at the line 529 + 530, i should to send back to NAS server with the Acces 
Reject with attribute h323-return-code == h323-return-code=2 not 0

..
520 Using Post-Auth-Type Reject
521 +- entering group REJECT {...}
522 [attr_filter.access_reject] expand: %{User-Name} - 087301
523  attr_filter: Matched entry DEFAULT at line 11
524 ++[attr_filter.access_reject] returns updated
525 Delaying reject of request 9 for 1 seconds
526 Going to the next request
527 Waking up in 0.9 seconds.
528 Sending delayed reject for request 9
529 Sending Access-Reject of id 206 to 172.26.0.8 port 1645
530 h323-return-code == h323-return-code=0

and the man unlang says the unlang is used in the configuration file -- 
radiusd.conf

and there are some blocks in radiusd.conf such as listen block, module block, 
log block ...
where should i put the unlang 
as your suggestion the Post-Auth-Type REJECT. but i dont know where to put it
so put it at the end of the radiusd.conf
the radiusd.conf
...
$INCLUDE sites-enabled/

Post-Auth-Type REJECT {
h323-return-code := h323-return-code=2
}

but it doesnt work :(

Thank you
Ha`-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Need Help on Radius - accounting respond

2008-12-14 Thread Do Nguyen Ha
Hi all


the FR receive the accounting request:
rad_recv: Accounting-Request packet from host 172.26.0.8 port 1645, id=186, 
length=399
User-Name = 087301
NAS-IP-Address = 0.0.0.0
Service-Type = Dialout-Framed-User
Class = 0x436c6173733d333030
Cisco-AVPair = h323-incoming-conf-id=b97aff16 c99911dd 8125d127 
98296413 
h323-conf-id = h323-conf-id=b97aff16 c99911dd 8125d127 98296413 
h323-setup-time = h323-setup-time= 4:43:17.000 UTC Mon Dec 15 2008
h323-connect-time = h323-connect-time= 4:43:21.000 UTC Mon Dec 15 2008
h323-call-type = h323-call-type=VOIP
Called-Station-Id = 087312
Calling-Station-Id = 087301
Acct-Status-Type = Start
Acct-Session-Id = b97aff16 c99911dd 8125d127 98296413 
Event-Timestamp = Dec 15 2008 11:43:21 ICT
NAS-Port-Type = Ethernet

then FR should send accounting respond :
h323-credit-amount=customer balance at the time of authentication
h323-return-code=0(accept)/2(reject)
h323-billing-model=2
but FR send:
Sending Accounting-Response of id 192 to 172.26.0.8 port 1645

can the FR do that? if yes, where should i edit
if i want to send response to NAS i should add the attribute in the 
attrs.accounting-response :
h323-credit-amount=* ANY
h323-return-code=* ANY
h323-billing-model=* ANY

i check the attrs.accounting-reponse:
#
#   Configuration file for the rlm_attr_filter module.
#   Please see rlm_attr_filter(5) manpage for more information.
#
#   $Id$
#
#   This configuration file is used to remove almost all of the attributes
#   From an Accounting-Response message.  The RFC's say that an
#   Accounting-Response packet can contain only a few attributes.
#   We enforce that here.
#
DEFAULT
Vendor-Specific =* ANY,
Message-Authenticator =* ANY,
Proxy-State =* ANY,



1 more question: 
i read the man unlang times but cannot figure out how to use it
could you give the example for specific case such as Access Reject/ update the 
Access Reject/Accept

Thanks
Ha`-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Need help on Acocunting Respond

2008-12-11 Thread Do Nguyen Ha
Hi all

i use the FreeRadius to work with Cisco Softswitch SIP Server
i follow the instruction:
http://freeradius.org/radiusd/man/rlm_attr_filter.html
preacct
Filters Accounting-Request packets. 
accounting
Filters Accounting-Response packets. 

i edit the following file :
site-enable/default :
#  Filter attributes from the accounting response.
#attr_filter.accounting_response
preprocess :   with_cisco_vsa_hack = yes
acct_users :   
DEFAULT
User-Name := %{Stripped-User-Name:-%{User-Name}},
h323-return-code := h323-return-code=0


the problem i got in the Accounting respond :
Sending Accounting-Response of id 139 to 172.26.0.8 port 1645
User-Name := 087301
h323-return-code := h323-return-code=0
how do i run the sql query or do something to get the h323-return-code in the 
Accounting Request


Thanks
Ha`
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

need help on Access Reject

2008-12-08 Thread Do Nguyen Ha
Hi all

is there a way to insert the attribute
h323-return-code = 2 in the Access Reject message
i use the FreeRadius 1.1.7, 

Could you give me some advices

Thank you
Ha`-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Re: I've started to put the book online

2008-08-19 Thread Do Nguyen Ha

its good news for everyone who love FreeRadius :)


Date: Tue, 19 Aug 2008 09:23:06 +0200
From: Alan DeKok [EMAIL PROTECTED]
Subject: I've started to put the book online
To: FreeRadius users mailing list
freeradius-users@lists.freeradius.org
Message-ID: [EMAIL PROTECTED]
Content-Type: text/plain; charset=ISO-8859-1

http://deployingradius.com/book/

 Only parts of the first chapter are online.  It covers the basic
concepts behind RADIUS, and should hopefully address a number of common
misunderstandings about how it all works.

 Keep checking the site.  More will be coming later.

 Alan DeKok.


--

-
List info/subscribe/unsubscribe? See 
http://www.freeradius.org/list/users.html



End of Freeradius-Users Digest, Vol 40, Issue 81
 


-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Free Radius resource

2008-06-16 Thread Do Nguyen Ha

hi

when is this book launch, i am looking for it
and think many people are looking for it

Ha`


2008/6/14 Alan DeKok [EMAIL PROTECTED]:

Rogelio wrote:

Hi all, just started delving into RADIUS and have begun to take the
plunge with FreeRADIUS.

Any suggested books on the subject?  I see quite a few on the subject:


 The O'Reilly book is good if you know absolutely nothing about RADIUS.
 But 1/3 is from the RFC's (paraphrased), and another 1/3 is from the
FreeRADIUS documentation.

 The Wiley book has about 30 pages on RADIUS, the rest is about
technologies that you don't use.  And the RADIUS stuff is not that 
useful.


 Then, there's my book.  It's at about 200 pages, and has been at that
level for over a year.  I'm trying to find time to either finish it, or
to clean it up, and put it on the web.

 Alan DeKok.
-
List info/subscribe/unsubscribe? See 
http://www.freeradius.org/list/users.html


-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Need help on accounting - authentication

2008-06-12 Thread Do Nguyen Ha

Hi


is there a way to config Freeradius to use the same port for Accounting  
Authentication


if yes, please let me know how to edit


Thanks

Ha` 


-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Fw: need help on accounting respond

2008-06-09 Thread Do Nguyen Ha
hi all

i need help on account of freeradius

Accounting Respond Message:

AttributeID  Vendor ID Sub Attribute ID  Status   Attribute Name   Type 
  Value  
26  9  101  O 
h323-credit-amount  String  Customer balance at the  time of authentication 
 
26  9  103  M+   
h323-return-code  Integer  5
26  9  109  O 
h323-billing-modelInteger  Type of billing service for a  specific 
call:  

0 = credit customer (post-paid)  

1= debit card (prepaid)  

2= limited service (prepaid)  

3= limited service (postpaid)  
26  9  110  O  
h323-currency String Customer currency in the form of 
3-character value from ISO 4217 (e.g. USD)  


now i want freeradius reply to the client with Accounting Respond with the 
structure of message above

the M+ : is required

where do i edit to make it works



Thanks

Ha`
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

need help on accounting respond

2008-06-09 Thread Do Nguyen Ha




hi all

i need help on account of freeradius

Accounting Respond Message:

AttributeID  Vendor ID Sub Attribute ID  Status   Attribute Name 
Type   Value
26  9  101  O 
h323-credit-amount  String  Customer balance at the  time of 
authentication
26  9  103  M+ 
h323-return-code  Integer  5
26  9  109  O 
h323-billing-modelInteger  Type of billing service for a  specific 
call:


0 = credit customer (post-paid)

1= debit card (prepaid)

2= limited service (prepaid)

3= limited service (postpaid)
26  9  110  O 
h323-currency String Customer currency in the form of 
3-character value from ISO 4217 (e.g. USD)



now i want freeradius reply to the client with Accounting Respond with the 
structure of message above


the M+ : is required

where do i edit to make it works



Thanks

Ha`



Message: 4
Date: Mon, 09 Jun 2008 13:16:34 +0100
From: Ivan Kalik [EMAIL PROTECTED]
Subject: Re: Fw: need help on accounting respond
To: FreeRadius users mailing list
freeradius-users@lists.freeradius.org
Message-ID: [EMAIL PROTECTED]
Content-Type: text/plain; charset=ISO-8859-2

Wherever you keep user details - users file, sql, ldap, ...

Ivan Kalik
Kalik Informatika ISP





Hi IvanKalik

can you give me an example of it
i use MySQL, at this time only testing with some subscribers
the radacct table is now empty, what information should i put
could you give me an example of radacct table

i send attached file which is the sample of Accounting request

Thanks

Ha` 


radius - with Accounting Request.pcap
Description: Binary data
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Need help on FreeRadius CDR Tool

2008-06-05 Thread Do Nguyen Ha
Hi 

 manage the Cisco BTS 10200 system, and now i am assigned a task to work with 
the Radius
i choose the FreeRadius to work with Cisco BTS system

modify some config in radiusd.conf  clients.conf 

first, BTS send message Access Request to FreeRadius and then Freeradius send 
message Access Accept, they working properly

when BTS send message Account Start to Radius, there are a lot attribute and 
freeradius save them in the radacct table


this is the account start message structure:

Attribute ID Vendor ID Sub Attribute ID Status  
Attribute Name  Type  Value 
1   
   M-  User-Name  String
  ANI 
4   
   M-  NAS-IP-Address  IP Address   
   BTS IP address 
6   
   M-  Service-Type   Integer   
 Service Type = Outbound 
25  
  C+  Class String  
  CLASS Attribute 


26  9  1
 M-  h323-incoming-conf-id=value String 
 A unique number for identifying a calling session on a gateway, where a 
session is closed when the calling party hangs up.



 
26  9  24   
  M+  h323-conf-id  String  
Unique call identifier generated by the BTS. Used to distinguish the 
separate billable events (calls) within a single calling session.

 
26  9  25   
  M-  h323-setup-time  String   
   hh:mm:ss.mmm  ZON DDD MMM ##  Setup time in NTP format. 


26  9  28   
   M- h323-connect-time  String 
 hh:mm:ss.mmm  ZON DDD MMM ##  Connect time in NTP format. 


26  9  27   
   M+  h323-call-type  String   
  Telephony,VOIP 
30  
 C-Called-Station-ID  String
  DNIS 
31  
 C+  Calling-Station-ID  String 
 ANI 
40  
M+   Acct-Status-Type Integer   
   Acct-Status-Type = Start (1) 
44  
M+  Acct-Session-IDString   
   Accounting Session ID 
55  
M+  Event-Timestamp  Integer
  Event Time Stamp 
61  
M-NAS-Port-TypeInteger  
Ethernet (15) 

 

but in radacct , there some columm doesn't match with the message Account 
Start, i want to change the name of some columm to match the message 

what should i need to edit the sql.conf for this issue

On the CDR Tool, what should i need to edit to working properly

 

 

Thanks

 

Ha`
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html