freeradius.git
13 years agoAllow 'octet' attributes to have a fixed length.
Alan T. DeKok [Thu, 15 Jul 2010 09:48:56 +0000 (11:48 +0200)]
Allow 'octet' attributes to have a fixed length.

This is currently only for a few old attributes (ARAP-*), but the
same framework is leveraged for other attributes, too.  e.g. int, ipaddr

13 years agoFix arguments to paircreate
Alan T. DeKok [Thu, 15 Jul 2010 09:30:01 +0000 (11:30 +0200)]
Fix arguments to paircreate

13 years agoerrorcode may be NULL. Ignore it if so.
Alan T. DeKok [Thu, 8 Jul 2010 13:44:13 +0000 (15:44 +0200)]
errorcode may be NULL.  Ignore it if so.

Closes bug #39

13 years agoCertificates do not depend on index / serial
Alan T. DeKok [Thu, 8 Jul 2010 13:28:45 +0000 (15:28 +0200)]
Certificates do not depend on index / serial

Closes bug #64

13 years agoPack DHCP-BootFilename into header
Alan T. DeKok [Thu, 8 Jul 2010 11:06:15 +0000 (13:06 +0200)]
Pack DHCP-BootFilename into header

13 years agoAdded Motorola WimMAX dictionary
Alan T. DeKok [Wed, 7 Jul 2010 19:14:21 +0000 (21:14 +0200)]
Added Motorola WimMAX dictionary

13 years agoRe-worked PEAP state machine to be clearer
Alan T. DeKok [Wed, 7 Jul 2010 11:51:03 +0000 (13:51 +0200)]
Re-worked PEAP state machine to be clearer

13 years agoMoved eappeap_identity to its own function.
Alan T. DeKok [Wed, 7 Jul 2010 11:33:05 +0000 (13:33 +0200)]
Moved eappeap_identity to its own function.

13 years agoChanged multiple "if" statements to switch.
Alan T. DeKok [Wed, 7 Jul 2010 11:30:39 +0000 (13:30 +0200)]
Changed multiple "if" statements to switch.

13 years agoPatches for EAP-FAST as posted to the list 2010-01-19
Alan T. DeKok [Wed, 7 Jul 2010 14:50:47 +0000 (16:50 +0200)]
Patches for EAP-FAST as posted to the list 2010-01-19

by Maja Wolniewicz

13 years agoEnable passwd in coa send/recv
Alan T. DeKok [Tue, 6 Jul 2010 08:30:58 +0000 (10:30 +0200)]
Enable passwd in coa send/recv

13 years agoMap all types of attrs, not just int/string
Alan T. DeKok [Tue, 6 Jul 2010 08:30:11 +0000 (10:30 +0200)]
Map all types of attrs, not just int/string

13 years agoReturn on error
Alan T. DeKok [Mon, 5 Jul 2010 09:00:26 +0000 (11:00 +0200)]
Return on error

13 years agoNote that "password_attribute" is deprecated
Alan T. DeKok [Mon, 5 Jul 2010 09:00:11 +0000 (11:00 +0200)]
Note that "password_attribute" is deprecated

13 years agoRemoved "password_header" configuration
Alan T. DeKok [Mon, 5 Jul 2010 08:50:21 +0000 (10:50 +0200)]
Removed "password_header" configuration

13 years agoRemove "auto_header" flag.
Alan T. DeKok [Mon, 5 Jul 2010 08:49:10 +0000 (10:49 +0200)]
Remove "auto_header" flag.

13 years agoHandle detail files differently.
Alan T. DeKok [Fri, 2 Jul 2010 08:22:50 +0000 (10:22 +0200)]
Handle detail files differently.

13 years agoDon't use libltdl if we're using dlopen()
Alan T. DeKok [Thu, 1 Jul 2010 13:43:10 +0000 (15:43 +0200)]
Don't use libltdl if we're using dlopen()

13 years agoMore provisions for dlopen'ing self.
Alan T. DeKok [Thu, 1 Jul 2010 13:09:08 +0000 (15:09 +0200)]
More provisions for dlopen'ing self.

13 years agoRemove restrictions on TLVs must be WiMAX. It's not in 2.1.x
Alan T. DeKok [Thu, 1 Jul 2010 13:08:38 +0000 (15:08 +0200)]
Remove restrictions on TLVs must be WiMAX.  It's not in 2.1.x

13 years agoProvisions for RTLD_SELF, when all of the modules are statically linked in
Alan T. DeKok [Thu, 1 Jul 2010 12:54:22 +0000 (14:54 +0200)]
Provisions for RTLD_SELF, when all of the modules are statically linked in

13 years agoAllow exec in recv/send coa sections
Alan T. DeKok [Thu, 1 Jul 2010 10:47:25 +0000 (12:47 +0200)]
Allow exec in recv/send coa sections

13 years agoDo not delete "old" requests until they are free.
Alan T. DeKok [Wed, 30 Jun 2010 19:58:27 +0000 (21:58 +0200)]
Do not delete "old" requests until they are free.

If the request is in the queue for 30+ seconds, do NOT delete it.
Instead, mark it as "STOP PROCESSING", and do "wait_for_child_to_die",
which waits for a child thread to pick it up, and acknowledge that it's
done.  Once it's marked done, we can finally clean it up.

This may be the underlying issue behind bug #35

13 years agoChange default lifetime for dynamic clients from 1d to 1h
Alan T. DeKok [Wed, 30 Jun 2010 14:17:55 +0000 (16:17 +0200)]
Change default lifetime for dynamic clients from 1d to 1h

13 years agoRefer to the correct packet type.
Alan T. DeKok [Wed, 30 Jun 2010 09:00:39 +0000 (11:00 +0200)]
Refer to the correct packet type.

The CoA response is in the proxy reply, not in the main reply

13 years agoScan the number, not the leading \
Alan T. DeKok [Wed, 30 Jun 2010 08:57:27 +0000 (10:57 +0200)]
Scan the number, not the leading \

Fix for bug #89

13 years agoALWAYS save the MPPE keys for later.
Alan T. DeKok [Wed, 30 Jun 2010 08:05:56 +0000 (10:05 +0200)]
ALWAYS save the MPPE keys for later.

The TTLS && PEAP modules should take care of deleting the MPPE keys
if they don't want them.  The previous code would delete the keys
if an EAP-MSCHAPv2 request was proxied to a virtual server.  That was wrong...

13 years agoMore NAS-Port-Type values defined in random places
Alan T. DeKok [Tue, 29 Jun 2010 10:38:02 +0000 (12:38 +0200)]
More NAS-Port-Type values defined in random places

13 years agoAdded NAS-Port-Type values from RFC 4603
Alan T. DeKok [Tue, 29 Jun 2010 10:36:40 +0000 (12:36 +0200)]
Added NAS-Port-Type values from RFC 4603

13 years agoAs posted to the list
Alan T. DeKok [Tue, 29 Jun 2010 07:33:42 +0000 (09:33 +0200)]
As posted to the list

13 years agoRegister SQL-Group only if the query is defined
Alan T. DeKok [Mon, 28 Jun 2010 13:54:28 +0000 (15:54 +0200)]
Register SQL-Group only if the query is defined

13 years agoFix debug messages for incorrect shared secret
Alan T. DeKok [Sun, 27 Jun 2010 20:55:35 +0000 (22:55 +0200)]
Fix debug messages for incorrect shared secret

13 years agoWrap commands in "if ! output_file, then run command"
Alan T. DeKok [Sun, 27 Jun 2010 16:40:45 +0000 (18:40 +0200)]
Wrap commands in "if ! output_file, then run command"

This lets people run "./bootstrap" multiple times without problems.

13 years agoCheck for a working make before running it.
Alan T. DeKok [Sun, 27 Jun 2010 16:14:45 +0000 (18:14 +0200)]
Check for a working make before running it.

This lets us tell the difference between a non-existent make, and one
which exists, but failed the "make all" stage

13 years agoEnable 127.0.0.1:18120 for inner-tunnel testing
Alan T. DeKok [Sun, 27 Jun 2010 15:59:52 +0000 (17:59 +0200)]
Enable 127.0.0.1:18120 for inner-tunnel testing

13 years agoAdded more eapol_test tests
Alan T. DeKok [Sat, 26 Jun 2010 16:54:13 +0000 (18:54 +0200)]
Added more eapol_test tests

13 years agoBuild on systems without setuid
Alan T. DeKok [Tue, 22 Jun 2010 14:41:53 +0000 (16:41 +0200)]
Build on systems without setuid

13 years agoBuild on systems without fcntl
Alan T. DeKok [Tue, 22 Jun 2010 14:41:13 +0000 (16:41 +0200)]
Build on systems without fcntl

13 years agoBuild on systems without sys/un.h
Alan T. DeKok [Tue, 22 Jun 2010 14:40:27 +0000 (16:40 +0200)]
Build on systems without sys/un.h

13 years agoBuild on systems without fcntl
Alan T. DeKok [Tue, 22 Jun 2010 14:39:26 +0000 (16:39 +0200)]
Build on systems without fcntl

13 years agointerface is a #define on Mingw
Alan T. DeKok [Tue, 22 Jun 2010 14:37:54 +0000 (16:37 +0200)]
interface is a #define on Mingw

13 years agoAdd <instance>-SQL-Group, just like the LDAP module
Alan T. DeKok [Tue, 22 Jun 2010 12:19:56 +0000 (14:19 +0200)]
Add <instance>-SQL-Group, just like the LDAP module

13 years agoCorrect logic in pairmove2 now that we have vendor separate from attr
Alan T. DeKok [Sat, 26 Jun 2010 16:56:59 +0000 (18:56 +0200)]
Correct logic in pairmove2 now that we have vendor separate from attr

13 years agoMore descriptive error messages
Alan T. DeKok [Tue, 15 Jun 2010 10:12:12 +0000 (12:12 +0200)]
More descriptive error messages

13 years agoSimple rules to build HTML files if we don't have sphinx
Alan T. DeKok [Mon, 14 Jun 2010 08:50:06 +0000 (10:50 +0200)]
Simple rules to build HTML files if we don't have sphinx

13 years agoMakefile / index for Sphinx builds
Alan T. DeKok [Mon, 14 Jun 2010 08:44:58 +0000 (10:44 +0200)]
Makefile / index for Sphinx builds

We don't change the existing build, as we're in a "stable" release,
and we don't want to change functionality.

13 years agoMinor cleanups
Alan T. DeKok [Mon, 14 Jun 2010 08:44:46 +0000 (10:44 +0200)]
Minor cleanups

13 years agoManually pull from git "old-dev" branch
Alan T. DeKok [Mon, 14 Jun 2010 08:42:31 +0000 (10:42 +0200)]
Manually pull from git "old-dev" branch

13 years agoNew RST versions from bjlockie
Alan T. DeKok [Mon, 14 Jun 2010 08:42:09 +0000 (10:42 +0200)]
New RST versions from bjlockie

13 years agoMoved files without changing contents
Alan T. DeKok [Mon, 14 Jun 2010 08:41:15 +0000 (10:41 +0200)]
Moved files without changing contents

In preparation for commiting new RST versions

13 years agoFixes to make more modules build
Alan T. DeKok [Fri, 11 Jun 2010 12:54:07 +0000 (14:54 +0200)]
Fixes to make more modules build

13 years agoEnsure we do PINGs only for UDP packets.
Alan T. DeKok [Thu, 10 Jun 2010 08:58:04 +0000 (10:58 +0200)]
Ensure we do PINGs only for UDP packets.

13 years agoMade ONE caller for request_stats_final.
Alan T. DeKok [Mon, 31 May 2010 13:54:54 +0000 (15:54 +0200)]
Made ONE caller for request_stats_final.

It doesn't hurt to push some of the stats off until later.

13 years agoCatch "ping" packets before
Alan T. DeKok [Thu, 10 Jun 2010 08:07:04 +0000 (10:07 +0200)]
Catch "ping" packets before

13 years agoFix typo
Alan T. DeKok [Thu, 10 Jun 2010 06:08:54 +0000 (08:08 +0200)]
Fix typo

13 years agoCleaned up debug output to be readable
Alan T. DeKok [Wed, 9 Jun 2010 13:09:02 +0000 (15:09 +0200)]
Cleaned up debug output to be readable

13 years agoEnable MS-CHAPv1 support in radclient.
Alan T. DeKok [Wed, 9 Jun 2010 06:38:05 +0000 (08:38 +0200)]
Enable MS-CHAPv1 support in radclient.

13 years agoMove MS-CHAP code to separate files.
Alan T. DeKok [Wed, 9 Jun 2010 06:36:44 +0000 (08:36 +0200)]
Move MS-CHAP code to separate files.

13 years agoRemoved the "unix" module from the default configuration
Alan T. DeKok [Wed, 9 Jun 2010 06:31:46 +0000 (08:31 +0200)]
Removed the "unix" module from the default configuration

Few people do Unix authentication any more, and it is starting to
cause problems.

13 years agoInstall cryptpasswd as "radcrypt"
Alan T. DeKok [Tue, 8 Jun 2010 14:28:23 +0000 (16:28 +0200)]
Install cryptpasswd as "radcrypt"

13 years agoShorten debug message
Alan T. DeKok [Tue, 8 Jun 2010 13:15:23 +0000 (15:15 +0200)]
Shorten debug message

13 years agoUse correct variable to look up attributes in the dictionary
Alan T. DeKok [Thu, 10 Jun 2010 08:29:09 +0000 (10:29 +0200)]
Use correct variable to look up attributes in the dictionary

2.1.x use "attribute = attr << 16 | vendor".  In 2.2, we can
use (attr, vendor) directly

13 years agoFix proxying of inner tunneled requests
Alan T. DeKok [Tue, 8 Jun 2010 12:45:05 +0000 (14:45 +0200)]
Fix proxying of inner tunneled requests

Set the source/dst IP of the proxied packet to "unknown" in TTLS/PEAP

When sending, force the source IP address of the packet to whatever
the home server is using.

13 years agoIf we've parsed " in a string, set the length to the correct value
Alan T. DeKok [Tue, 8 Jun 2010 05:56:38 +0000 (07:56 +0200)]
If we've parsed " in a string, set the length to the correct value

13 years agoAllow parsing of IPv6 addresses as domain names
Alan T. DeKok [Tue, 8 Jun 2010 05:55:07 +0000 (07:55 +0200)]
Allow parsing of IPv6 addresses as domain names

13 years agoTell OpenSSL to NOT do "no session Id" sessions
Alan T. DeKok [Mon, 7 Jun 2010 21:02:08 +0000 (23:02 +0200)]
Tell OpenSSL to NOT do "no session Id" sessions

Found && fix by Andreas Hartmann

13 years agoBe more careful about parsing comments after bare words
Alan T. DeKok [Mon, 7 Jun 2010 08:38:55 +0000 (10:38 +0200)]
Be more careful about parsing comments after bare words

13 years agoFix typo
Alan T. DeKok [Mon, 7 Jun 2010 07:52:50 +0000 (09:52 +0200)]
Fix typo

13 years agoPlain EAP-MSCHAPv2 should return the MPPE keys.
Alan T. DeKok [Mon, 7 Jun 2010 07:05:30 +0000 (09:05 +0200)]
Plain EAP-MSCHAPv2 should return the MPPE keys.

This is needed for IKE

13 years agoMove retransmits + proxy failover into child thread
Alan T. DeKok [Tue, 1 Jun 2010 08:32:09 +0000 (10:32 +0200)]
Move retransmits + proxy failover into child thread

If we receive a retransmit, if the home server is still alive, the proxy
core just sends another retransmit to the home server.

If the home server is down, or we need to do some more work, push that
to a child thread.

13 years agoClean up code related to requests in child thread
Alan T. DeKok [Tue, 1 Jun 2010 08:26:21 +0000 (10:26 +0200)]
Clean up code related to requests in child thread

There is now a "thread_pool_addrequest" when there's no pthread.
It calls radius_handle_request() as before.  This makes the event.c
code a little simpler.

Make "poll detail" code call generic socket handler code.  Less code,
and one central place for handling things

13 years agoDelay decoding of packet until we are in the child thread
Alan T. DeKok [Tue, 1 Jun 2010 08:20:09 +0000 (10:20 +0200)]
Delay decoding of packet until we are in the child thread

This also delays removing the packet from the proxy hash.  When the server
is busy, this means that the ID's are used for extended periods of time
as compared to 2.1.x.  However, if the server is busy and can't process
existing requests, then it has no business proxying even more packets
upstream.

13 years agoBump the module magic number.
Alan T. DeKok [Wed, 28 Apr 2010 08:01:25 +0000 (10:01 +0200)]
Bump the module magic number.

The APIs are completely different, so the server core should enforce
a prohibition on linking old modules to the new server

13 years agoMake MSCHAP attribute lookups use Microsofts vendor-id
Alan T. DeKok [Wed, 28 Apr 2010 06:48:29 +0000 (08:48 +0200)]
Make MSCHAP attribute lookups use Microsofts vendor-id

This was missed in earlier commits

13 years agoIgnore more auto-generated files
Alan T. DeKok [Wed, 28 Apr 2010 06:42:42 +0000 (08:42 +0200)]
Ignore more auto-generated files

13 years agoMake it closer to v2.1.x for consistency
Alan T. DeKok [Wed, 28 Apr 2010 06:40:59 +0000 (08:40 +0200)]
Make it closer to v2.1.x for consistency

13 years agoRemove all references to "vp->attribute & 0xffff"
Alan T. DeKok [Tue, 27 Apr 2010 08:51:22 +0000 (10:51 +0200)]
Remove all references to "vp->attribute & 0xffff"

They now refer to vp->vendor

13 years agoFix args to dict_addattr()
Alan T. DeKok [Tue, 27 Apr 2010 08:51:08 +0000 (10:51 +0200)]
Fix args to dict_addattr()

13 years agoAdded back label 'stop_processing'
Alan T. DeKok [Wed, 14 Apr 2010 12:30:35 +0000 (14:30 +0200)]
Added back label 'stop_processing'

13 years agoRemove all limitations on vendor IDs being less than 64K
Alan T. DeKok [Thu, 17 Dec 2009 10:30:54 +0000 (11:30 +0100)]
Remove all limitations on vendor IDs being less than 64K

13 years agoFix argument to pairfind
Alan T. DeKok [Thu, 17 Dec 2009 10:30:32 +0000 (11:30 +0100)]
Fix argument to pairfind

13 years agoUse new API
Alan T. DeKok [Thu, 17 Dec 2009 10:04:49 +0000 (11:04 +0100)]
Use new API

13 years agoMake this unsigned, too
Alan T. DeKok [Tue, 13 Oct 2009 10:12:01 +0000 (12:12 +0200)]
Make this unsigned, too

13 years agoOnly WiMAX attributes can be of type tlv
Alan T. DeKok [Tue, 13 Oct 2009 09:15:20 +0000 (11:15 +0200)]
Only WiMAX attributes can be of type tlv

13 years agoNested TLVs 4 deep now work...
Alan T. DeKok [Tue, 13 Oct 2009 09:12:59 +0000 (11:12 +0200)]
Nested TLVs 4 deep now work...

13 years agoFix to encode properly
Alan T. DeKok [Tue, 13 Oct 2009 08:57:46 +0000 (10:57 +0200)]
Fix to encode properly

13 years agoEnforce limitations
Alan T. DeKok [Tue, 13 Oct 2009 08:48:24 +0000 (10:48 +0200)]
Enforce limitations

13 years agoUse external array for shifting attributes to VPs
Alan T. DeKok [Tue, 13 Oct 2009 08:46:54 +0000 (10:46 +0200)]
Use external array for shifting attributes to VPs

13 years agoFirst stab at parameterizing tlv nonsense
Alan T. DeKok [Tue, 13 Oct 2009 08:43:58 +0000 (10:43 +0200)]
First stab at parameterizing tlv nonsense

13 years agoCan't these retards check for duplicate attribute names?
Alan T. DeKok [Fri, 9 Oct 2009 12:06:35 +0000 (14:06 +0200)]
Can't these retards check for duplicate attribute names?

13 years agodded the rest of the insane attributes
Alan T. DeKok [Fri, 9 Oct 2009 12:05:09 +0000 (14:05 +0200)]
dded the rest of the insane attributes

13 years agoFix VSA tunnel encryption. Allow sub-TLVs to be encrypted
Alan T. DeKok [Fri, 9 Oct 2009 09:59:26 +0000 (11:59 +0200)]
Fix VSA tunnel encryption.  Allow sub-TLVs to be encrypted

13 years agoDefined a whack more attributes.
Alan T. DeKok [Fri, 9 Oct 2009 09:23:51 +0000 (11:23 +0200)]
Defined a whack more attributes.

OMFG.  They nest TLVs 4 deep!  What the FUCK is up with that?

13 years agoRenamed evil function to be less evil
Alan T. DeKok [Fri, 9 Oct 2009 08:17:56 +0000 (10:17 +0200)]
Renamed evil function to be less evil

13 years agoDecode 3-level TLVs
Alan T. DeKok [Fri, 9 Oct 2009 08:16:12 +0000 (10:16 +0200)]
Decode 3-level TLVs

13 years agoNow properly handles continuation without memcmp && memmove
Alan T. DeKok [Thu, 8 Oct 2009 15:41:55 +0000 (17:41 +0200)]
Now properly handles continuation without memcmp && memmove

13 years agoNow packing WiMAX TLVs, too
Alan T. DeKok [Thu, 8 Oct 2009 13:50:16 +0000 (15:50 +0200)]
Now packing WiMAX TLVs, too

13 years agoAdded support for non-TLV WiMAX VSAs
Alan T. DeKok [Thu, 8 Oct 2009 13:41:11 +0000 (15:41 +0200)]
Added support for non-TLV WiMAX VSAs

13 years agoFirst stab at rewrite of vp2attr.
Alan T. DeKok [Thu, 8 Oct 2009 13:20:46 +0000 (15:20 +0200)]
First stab at rewrite of vp2attr.

This makes the code MUCH clearer, with fewer intermediate variables.

It also removes the WiMAX functionality entirely, but that will
be re-added later.

13 years agoSimplify RFC format attributes
Alan T. DeKok [Thu, 8 Oct 2009 12:55:51 +0000 (14:55 +0200)]
Simplify RFC format attributes