Koozali.org: home of the SME Server

radius server for copspot

Offline obelix

  • 6
  • +0/-0
radius server for copspot
« on: January 12, 2008, 03:36:18 PM »
Hello all,

I have been trying to setup radius to work with CopSpot to no avail :( I've gone through all the SME server forum listed below:

http://forums.contribs.org/index.php?topic=38387.0
http://forums.contribs.org/index.php?topic=21568.0

I have added the client on the /etc/raddb/clients.conf and saved it, but everytime I run signal-event remoteaccess-update (I assume you would need this to tell radiusd to load the updated settings) the entry that I made earlier got deleted.

So now I am relying on this forum to provide a solution for this issue, feel free to tell me if I need to add further details. Thank you in advance !

Offline mmccarn

  • *
  • 2,627
  • +10/-0
Re: radius server for copspot
« Reply #1 on: January 12, 2008, 03:58:52 PM »
Quote from: /etc/raddb/clients.conf
#------------------------------------------------------------
#              !!DO NOT MODIFY THIS FILE!!
#
# Manual changes will be lost when this file is regenerated.
#
# Please read the developer's guide, which is available
# at http://www.contribs.org/development/
#
# Copyright (C) 1999-2006 Mitel Networks Corporation
#------------------------------------------------------------

This means that this is a SME "templated" file, which is re-generated automatically at certain times based on the "template fragments" found in the folder named /etc/e-smith/templates/path/to/config/file (in this case, there are two files in the folder named /etc/e-smith/templates/etc/raddb/clients.conf).

To test a configuration change, it is enough to edit the config file manually and restart the associated service - but when you run signal-event remoteaccess-update, your changes are removed and the file is re-generated from the original template fragments.

Try this:
1) edit the file manually
2) restart the radius service using sv restart radiusd
3) once you know your changes work as desired, create a "custom" template fragment for /etc/raddb/clients.conf as follows
Code: [Select]
mkdir -p /etc/e-smith/templates-custom/etc/raddb/clients.conf
pico -w /etc/e-smith/templates-custom/etc/raddb/clients.conf/30MyNewRadiusClient

* Start the custom template name with "30" so that it comes after the original SME pieces, whose fragment names start with "10" and "20"
* Replace MyNewRadiusClient with something meaningful to you
* Add your customizations to the new template fragment

Now, when you re-generate the /etc/radiusd/clients.conf using

signal-event remoteaccess-update

or

expand-template /etc/radiusd/clients.conf

you should get your customizations added to the end of the file automatically.

Additionally, your customizations will be included in SME backups, will survive system upgrades, etc, etc.

Read more about SME templates at http://smemirror.fullnet.co.uk/contribs/gordonr/devguide/html/c610.htm

Offline obelix

  • 6
  • +0/-0
Re: radius server for copspot
« Reply #2 on: January 12, 2008, 04:21:25 PM »
Hi mmccarn,

Thank you for your quick reply, I just did what you suggested and the message in radius.log "ignoring unknown client" is gone now :), but I have been getting Info: rlm_passwd: Adding "Auth-Type = MS-CHAP" message now. Does it mean that I have to change the authentication method?

By the way, I have been able to test the CopSpot using radius server in windoze, but we all agree that windoze machine are bad for you, so thats why I keep persistent to have this setup working with SME server.


Offline mmccarn

  • *
  • 2,627
  • +10/-0
Re: radius server for copspot
« Reply #3 on: January 12, 2008, 05:27:03 PM »
Sorry - I know enough about SME templating to point out where you were going wrong before, but I know nothing about radius...

Offline obelix

  • 6
  • +0/-0
Re: radius server for copspot
« Reply #4 on: January 13, 2008, 02:23:26 AM »
thanks again for your post, just wondering if there is anyone else who would be able to help?

Offline Marcoof

  • 18
  • +0/-0
Re: radius server for copspot
« Reply #5 on: January 16, 2008, 10:14:09 PM »
Hi !!

I test the couple copspot / sme quickly 2 month before.
the message "ignoring unknown client" say you must edit
the files /etc/raddb/clients.conf and add your copspot subnet and secret.
Best regards,
Marc

Offline obelix

  • 6
  • +0/-0
Re: radius server for copspot
« Reply #6 on: January 16, 2008, 11:52:41 PM »
Hi Marc,

Thanks for your update, however I have managed to get rid of that issue. What remain to be a problem now is that I have to hard code the username & password on /etc/raddb/users for the setup to work, where as I want to be able to authenticate CopSpot users against SME's local user through /etc/passwd or local unix authentication mechanism. In other words, I would like to be able to add CopSpot users from server-manager and somehow get a valid authentication.

Just wondering if anyone come across similar setting?

Cheers,

Offline Marcoof

  • 18
  • +0/-0
Re: radius server for copspot
« Reply #7 on: January 17, 2008, 01:20:17 PM »
Yes me !
working for me if user/password in text.
but for a perfect integration, need to use ldap.
Marcoof

Offline obelix

  • 6
  • +0/-0
Re: radius server for copspot
« Reply #8 on: January 17, 2008, 01:31:24 PM »
Hi Marcoof,

That's great! Would you mind sharing how you did that? I mean how to setup the username/password in text? Thanks heaps...


Offline Marcoof

  • 18
  • +0/-0
Re: radius server for copspot
« Reply #9 on: January 22, 2008, 01:10:01 PM »
Hi !

I come back to home this week.
I'll try to help you if you havent found by yourself.
Marcoof

Offline obelix

  • 6
  • +0/-0
Re: radius server for copspot
« Reply #10 on: January 22, 2008, 01:28:03 PM »
Hi again,

Yes please! Could you please show me example on how you do that (authentication using plain text, through /etc/passwd)?

Thank you in advance.