freeradius.git
10 years agoFix doxygen release_3_0_0_rc1
Alan T. DeKok [Fri, 6 Sep 2013 14:37:33 +0000 (10:37 -0400)]
Fix doxygen

10 years agoUse AUTZ rules for AUTH groups. Fixes #425
Alan T. DeKok [Fri, 6 Sep 2013 14:05:57 +0000 (10:05 -0400)]
Use AUTZ rules for AUTH groups.  Fixes #425

10 years agoLog the first name of the group
Alan T. DeKok [Fri, 6 Sep 2013 14:05:25 +0000 (10:05 -0400)]
Log the first name of the group

So we see "Auth-Type foo {...}"
instead of "group foo {...}"

10 years agoRe-enable virtual attributes for comparison. Fixes #400
Alan T. DeKok [Thu, 5 Sep 2013 15:40:26 +0000 (11:40 -0400)]
Re-enable virtual attributes for comparison.  Fixes #400

10 years agoMissing newline
Arran Cudbard-Bell [Wed, 4 Sep 2013 21:23:51 +0000 (22:23 +0100)]
Missing newline

10 years agoFix shared-libs
Arran Cudbard-Bell [Wed, 4 Sep 2013 19:13:23 +0000 (20:13 +0100)]
Fix shared-libs

10 years agoIn debug builds, call assertion on panic
Alan T. DeKok [Wed, 4 Sep 2013 17:35:57 +0000 (13:35 -0400)]
In debug builds, call assertion on panic

10 years agoBe more careful about calling request_done(). Should fix #419
Alan T. DeKok [Wed, 4 Sep 2013 17:33:53 +0000 (13:33 -0400)]
Be more careful about calling request_done().  Should fix #419

10 years agoFixes for doxygen
Alan T. DeKok [Wed, 4 Sep 2013 17:07:45 +0000 (13:07 -0400)]
Fixes for doxygen

10 years agoUse the default request if there's no "." in the reference.
Alan T. DeKok [Wed, 4 Sep 2013 14:41:52 +0000 (10:41 -0400)]
Use the default request if there's no "." in the reference.

update outer.reply {
User-Name := foo
}

ends up parsing "User-Name" with a default list of "outer",
BUT because "User-Name" has no ".", the old code would return
a hard-coded CURRENT

10 years agoAdded %{debug_attr:...} from master
Alan T. DeKok [Wed, 4 Sep 2013 14:11:59 +0000 (10:11 -0400)]
Added %{debug_attr:...} from master

With some simplifications

10 years agoUse 'da' for DICT_ATTR*. "attribute' is for 'int'
Alan T. DeKok [Wed, 4 Sep 2013 13:44:36 +0000 (09:44 -0400)]
Use 'da' for DICT_ATTR*.  "attribute' is for 'int'

10 years agoSkip '&' on attribute maps. Closes #423
Alan T. DeKok [Wed, 4 Sep 2013 12:33:45 +0000 (08:33 -0400)]
Skip '&' on attribute maps.  Closes #423

And check return codes from request_name / list_name

10 years agoUpdate priority from child, too. Closes #424
Alan T. DeKok [Wed, 4 Sep 2013 12:22:28 +0000 (08:22 -0400)]
Update priority from child, too.  Closes #424

10 years agoDefine grouptype as an enum for debugging purposes
Arran Cudbard-Bell [Tue, 3 Sep 2013 23:18:29 +0000 (00:18 +0100)]
Define grouptype as an enum for debugging purposes

10 years agomap may return NULL
Alan T. DeKok [Tue, 3 Sep 2013 12:45:15 +0000 (08:45 -0400)]
map may return NULL

10 years agoDo a second pass over the conditions. Fixes #421
Alan T. DeKok [Tue, 3 Sep 2013 12:00:04 +0000 (08:00 -0400)]
Do a second pass over the conditions.  Fixes #421

Modules can register new attributes, so we may need to convert
literal comparisons to module comparisons.

The core can register new values for Auth-Type && friends
so we need to do a second pass to see if a failed lookup in pass1
is really a failure, or simply an early binding.

The next step is to add code to mark up late-registered paircompare
functions

10 years agoAllow for one/two-pass compilation of conditions.
Alan T. DeKok [Tue, 3 Sep 2013 01:32:48 +0000 (21:32 -0400)]
Allow for one/two-pass compilation of conditions.

If we allow two-pass compilation, certain errors are suppressed,
and the condition gets marked with a "pass2 flag"

10 years agoAdded "walk" function to conditions
Alan T. DeKok [Mon, 2 Sep 2013 13:30:51 +0000 (09:30 -0400)]
Added "walk" function to conditions

So that we can do post-processing

10 years agoFix ${value} expansion in backticked config pairs
Arran Cudbard-Bell [Tue, 3 Sep 2013 11:51:48 +0000 (12:51 +0100)]
Fix ${value} expansion in backticked config pairs

10 years agoOnly fallback to dynamic search if no attributes exist, or we have a failure of some...
Arran Cudbard-Bell [Tue, 3 Sep 2013 01:42:01 +0000 (02:42 +0100)]
Only fallback to dynamic search if no attributes exist, or we have a failure of some kind

10 years agoand another logic bug in ldap group code
Arran Cudbard-Bell [Tue, 3 Sep 2013 01:18:31 +0000 (02:18 +0100)]
and another logic bug in ldap group code

10 years agoLimit to -1, 0, 1 in normal operation so we can use -2 for error
Arran Cudbard-Bell [Tue, 3 Sep 2013 01:08:58 +0000 (02:08 +0100)]
Limit to -1, 0, 1 in normal operation so we can use -2 for error

10 years agoNot added to release branch
Arran Cudbard-Bell [Tue, 3 Sep 2013 00:36:34 +0000 (01:36 +0100)]
Not added to release branch

10 years agoFix broken group comparison logic
Arran Cudbard-Bell [Tue, 3 Sep 2013 00:35:11 +0000 (01:35 +0100)]
Fix broken group comparison logic

10 years agoPrint additional helpful group related debug
Arran Cudbard-Bell [Tue, 3 Sep 2013 00:06:41 +0000 (01:06 +0100)]
Print additional helpful group related debug

10 years agoTalloced strings get freed with talloc...?
Arran Cudbard-Bell [Mon, 2 Sep 2013 23:52:58 +0000 (00:52 +0100)]
Talloced strings get freed with talloc...?

10 years agoTypo
Arran Cudbard-Bell [Mon, 2 Sep 2013 23:36:35 +0000 (00:36 +0100)]
Typo

10 years agoDon't forget the NULL byte when copying VALUE_PAIR values
Arran Cudbard-Bell [Mon, 2 Sep 2013 23:32:50 +0000 (00:32 +0100)]
Don't forget the NULL byte when copying VALUE_PAIR values

10 years agoFix !* in update sections for non string attributes
Arran Cudbard-Bell [Mon, 2 Sep 2013 22:45:59 +0000 (23:45 +0100)]
Fix !* in update sections for non string attributes

10 years agoSet SQL username properly
Arran Cudbard-Bell [Mon, 2 Sep 2013 20:54:55 +0000 (21:54 +0100)]
Set SQL username properly

10 years agoRemove incorrect entry for membership_attribute
Arran Cudbard-Bell [Sun, 1 Sep 2013 15:07:18 +0000 (16:07 +0100)]
Remove incorrect entry for membership_attribute

10 years agounlang update sections support exec
Arran Cudbard-Bell [Sun, 1 Sep 2013 11:23:09 +0000 (12:23 +0100)]
unlang update sections support exec

10 years agoUse destructors to do the cleanup for VALUE_PAIRs
Arran Cudbard-Bell [Sat, 31 Aug 2013 16:56:49 +0000 (17:56 +0100)]
Use destructors to do the cleanup for VALUE_PAIRs

10 years agoFix -Wsometimes-uninitialized
Arran Cudbard-Bell [Fri, 30 Aug 2013 13:15:33 +0000 (14:15 +0100)]
Fix -Wsometimes-uninitialized

10 years agoRecord whether the server was built with NDEBUG in features.h
Arran Cudbard-Bell [Fri, 30 Aug 2013 13:14:20 +0000 (14:14 +0100)]
Record whether the server was built with NDEBUG in features.h

10 years agoSprinkle VERIFY_VP throughout the encoder
Arran Cudbard-Bell [Wed, 28 Aug 2013 13:38:32 +0000 (14:38 +0100)]
Sprinkle VERIFY_VP throughout the encoder

10 years agoCorrect typo. We should use foreach_depth as the request data index not stack depth.
Arran Cudbard-Bell [Tue, 27 Aug 2013 16:43:19 +0000 (17:43 +0100)]
Correct typo.  We should use foreach_depth as the request data index not stack depth.

Various whitespace fixes

10 years agoCorrect logic for "elsif"
Alan T. DeKok [Mon, 26 Aug 2013 12:25:40 +0000 (08:25 -0400)]
Correct logic for "elsif"

10 years agoClean up debug / info messages
Alan T. DeKok [Mon, 26 Aug 2013 12:16:46 +0000 (08:16 -0400)]
Clean up debug / info messages

10 years agoInitialize "found"
Alan T. DeKok [Mon, 26 Aug 2013 12:01:54 +0000 (08:01 -0400)]
Initialize "found"

10 years agoFix typo in debug message
Alan T. DeKok [Sun, 25 Aug 2013 14:34:27 +0000 (10:34 -0400)]
Fix typo in debug message

10 years agoFix placement of parse error in condition
Alan T. DeKok [Sat, 24 Aug 2013 14:23:01 +0000 (10:23 -0400)]
Fix placement of parse error in condition

10 years agoLoad Python with RTLD_GLOBAL to ensure symbols are accessible by dynload libraries...
Arran Cudbard-Bell [Sat, 24 Aug 2013 18:27:33 +0000 (19:27 +0100)]
Load Python with RTLD_GLOBAL to ensure symbols are accessible by dynload libraries / C extensions (by Zach Kanzler)

10 years agoMove the stringify macros to build.h
Arran Cudbard-Bell [Sat, 24 Aug 2013 17:02:42 +0000 (18:02 +0100)]
Move the stringify macros to build.h

10 years agoRemove extraneous assertion. Closes #414.
Alan T. DeKok [Sat, 24 Aug 2013 14:11:58 +0000 (10:11 -0400)]
Remove extraneous assertion.  Closes #414.

10 years agoIf there's no packet, don't add module_failure_msg. Closes #407
Alan T. DeKok [Sat, 24 Aug 2013 14:05:01 +0000 (10:05 -0400)]
If there's no packet, don't add module_failure_msg.  Closes #407

10 years agoDon't set home server to NULL. It's needed for other things
Alan T. DeKok [Fri, 23 Aug 2013 19:37:13 +0000 (15:37 -0400)]
Don't set home server to NULL.  It's needed for other things

10 years agoFix a typo
Alan T. DeKok [Fri, 23 Aug 2013 13:06:46 +0000 (09:06 -0400)]
Fix a typo

10 years agoWhoops... handle MOD_CASE, too
Alan T. DeKok [Fri, 23 Aug 2013 12:46:24 +0000 (08:46 -0400)]
Whoops... handle MOD_CASE, too

10 years agoRewrite the modcall MOD_* handlers. Updates #404.
Alan T. DeKok [Fri, 23 Aug 2013 02:32:58 +0000 (22:32 -0400)]
Rewrite the modcall MOD_* handlers.  Updates #404.

The old code wasn't worth debugging.  With a few hours work,
the new code is simpler, more understandable, and avoids the
bug entirely.

10 years agoClean up "close socket" routines.
Alan T. DeKok [Tue, 20 Aug 2013 14:21:37 +0000 (10:21 -0400)]
Clean up "close socket" routines.

We use the new rbtree DeleteOrder when walking over the packet list.
When the "eol tcp/proxy listener" callback is run, it can return
"please delete this node", instead of calling rbtree_delete.

Doing that allows the walker to be aware of deletions, unlike
before.

This turned out to make the code simpler, and the whole event fd
handling has become more robust.

10 years agoPort new logging macros to release branch
Arran Cudbard-Bell [Tue, 20 Aug 2013 13:30:04 +0000 (14:30 +0100)]
Port new logging macros to release branch

10 years agodon't segv printing interfaceid
Arran Cudbard-Bell [Thu, 15 Aug 2013 17:16:33 +0000 (18:16 +0100)]
don't segv printing interfaceid

10 years agoDon't segv if asked to print a null value
Arran Cudbard-Bell [Fri, 16 Aug 2013 17:47:54 +0000 (18:47 +0100)]
Don't segv if asked to print a null value

10 years agoFix segv in rlm_expiration
Arran Cudbard-Bell [Tue, 20 Aug 2013 13:02:30 +0000 (14:02 +0100)]
Fix segv in rlm_expiration

vp_strvalue no longer available for none string attributes

10 years agoSimplify "proxy anew" code
Alan T. DeKok [Fri, 16 Aug 2013 13:51:55 +0000 (09:51 -0400)]
Simplify "proxy anew" code

Now that the packet list re-uses Ids less often

10 years agoSimplify ID allocation so that we don't loop over all IDs
Alan T. DeKok [Fri, 16 Aug 2013 13:48:24 +0000 (09:48 -0400)]
Simplify ID allocation so that we don't loop over all IDs

Instead, we allocate a 256-entry array of random IDs (all unique)
and gradually use them.  When the array is empty, we re-fill it.

10 years agoUnify error logic
Alan T. DeKok [Fri, 16 Aug 2013 12:59:52 +0000 (08:59 -0400)]
Unify error logic

10 years agoBuild the rbmonkey test tool
Alan T. DeKok [Fri, 16 Aug 2013 03:01:17 +0000 (23:01 -0400)]
Build the rbmonkey test tool

10 years agoFormatting and warning fixes
Alan T. DeKok [Fri, 16 Aug 2013 03:01:06 +0000 (23:01 -0400)]
Formatting and warning fixes

10 years agoA test file for libradius rbtree ops
skids [Tue, 25 Jun 2013 22:52:15 +0000 (18:52 -0400)]
A test file for libradius rbtree ops
    Verifies red/black counts to all child nodes after adds/deletes
    Tests DeleteOrder; code provided in comments for vanilla rbtree_delete.
    Build system magic necessary for this is beyond me.
    It's a start at least

10 years agoAdd a batch deletion mode to rbtree_walk
skids [Tue, 25 Jun 2013 22:47:14 +0000 (18:47 -0400)]
Add a batch deletion mode to rbtree_walk

   Walks the tree calling callbacks as per InOrder
   Allows callback to ask for deletion of records after evaluating criteria
   All callbacks and deletions done while lock is held

10 years agoAdd rbtree_callbydata for sane threadsafe/garbage-collected operations
skids [Thu, 20 Jun 2013 20:03:20 +0000 (16:03 -0400)]
Add rbtree_callbydata for sane threadsafe/garbage-collected operations

  When working with an rbtree which is exposed to multiple threads,
  it is not safe to do much of anything with data retrieved by functions
  such as rbtree_finddata, other than to feed it directly to rbtree_delete.

  This is because once rbtree_finddata has returned, another thread may
  obtain a pointer to that data (and hence may begin mangling non-key
  material such as container_of or any child allocs.)  This is especially
  true for rbtrees that have a freeNode garbage collection routine defined.

  This function allows safe operations while the rbtree lock is still
  held.  It also allows for a conditional delete operation based on
  criteria which may only be safe to ascertain while the lock is held.
  In addition to short operations, it could be used, with due care, to
  trylock a more granular lock associated with the key before deleting
  the key or before operating with it outside of the rbtree lock.

10 years agoRemove redundant headers
Alan T. DeKok [Thu, 15 Aug 2013 13:12:33 +0000 (09:12 -0400)]
Remove redundant headers

10 years agoRemove redundant headers
Alan T. DeKok [Thu, 15 Aug 2013 13:12:17 +0000 (09:12 -0400)]
Remove redundant headers

10 years agopacket list id alloc/free now inserts / yanks the packet, too
Alan T. DeKok [Wed, 14 Aug 2013 16:29:59 +0000 (12:29 -0400)]
packet list id alloc/free now inserts / yanks the packet, too

10 years agoMade more functions return bool
Alan T. DeKok [Wed, 14 Aug 2013 16:21:33 +0000 (12:21 -0400)]
Made more functions return bool

10 years agoRemove talloc asserts
Alan T. DeKok [Wed, 14 Aug 2013 16:17:00 +0000 (12:17 -0400)]
Remove talloc asserts

some of the time, the packet is on the stack, and not talloc'd

10 years agoReturn codes are boolean
Alan T. DeKok [Wed, 14 Aug 2013 14:59:05 +0000 (10:59 -0400)]
Return codes are boolean

10 years agoMissed in earlier commit
Alan T. DeKok [Wed, 14 Aug 2013 14:40:57 +0000 (10:40 -0400)]
Missed in earlier commit

10 years agoUse correct arguments to talloc destructors
Alan T. DeKok [Wed, 14 Aug 2013 14:23:10 +0000 (10:23 -0400)]
Use correct arguments to talloc destructors

10 years agoCheck return code of packet_list_yank
Alan T. DeKok [Wed, 14 Aug 2013 14:14:55 +0000 (10:14 -0400)]
Check return code of packet_list_yank

10 years agoMade packet_list_yank return a bool for success/failure
Alan T. DeKok [Wed, 14 Aug 2013 14:14:32 +0000 (10:14 -0400)]
Made packet_list_yank return a bool for success/failure

10 years agoAdded VERIFY_PACKET, too
Alan T. DeKok [Wed, 14 Aug 2013 14:09:13 +0000 (10:09 -0400)]
Added VERIFY_PACKET, too

10 years agoFix more issues for new v3 API
Alan T. DeKok [Tue, 13 Aug 2013 13:06:15 +0000 (09:06 -0400)]
Fix more issues for new v3 API

10 years agoCorrect call to paircreate in radeapclient
Olivier Beytrison [Tue, 13 Aug 2013 09:56:44 +0000 (11:56 +0200)]
Correct call to paircreate in radeapclient

10 years agoFix horrific spacing issue.
Alan T. DeKok [Mon, 12 Aug 2013 19:39:30 +0000 (15:39 -0400)]
Fix horrific spacing issue.

10 years agoActually use virtual server when proxying to it. Closes #375
Alan T. DeKok [Mon, 12 Aug 2013 14:21:55 +0000 (10:21 -0400)]
Actually use virtual server when proxying to it.  Closes #375

10 years agofree -> talloc_free
Alan T. DeKok [Mon, 12 Aug 2013 13:16:47 +0000 (09:16 -0400)]
free -> talloc_free

10 years agoOnly print foreach close brace once. Closes #377
Alan T. DeKok [Sun, 11 Aug 2013 14:39:09 +0000 (10:39 -0400)]
Only print foreach close brace once.  Closes #377

10 years agoRemove from the proxy list if we can't insert it
Alan T. DeKok [Fri, 9 Aug 2013 15:13:36 +0000 (11:13 -0400)]
Remove from the proxy list if we can't insert it

10 years agoDon't smash passwords with newly alloc'd zero array
Alan T. DeKok [Fri, 9 Aug 2013 13:26:00 +0000 (09:26 -0400)]
Don't smash passwords with newly alloc'd zero array

10 years agoDon't iterate over head attribute twice Fixes #401
Arran Cudbard-Bell [Wed, 7 Aug 2013 16:57:31 +0000 (17:57 +0100)]
Don't iterate over head attribute twice Fixes #401

10 years agoUpdates from latest doc
Alan T. DeKok [Wed, 7 Aug 2013 01:05:07 +0000 (21:05 -0400)]
Updates from latest doc

10 years agoTypo in default ldap config
Arran Cudbard-Bell [Tue, 6 Aug 2013 12:46:01 +0000 (13:46 +0100)]
Typo in default ldap config

10 years agoFix logic error in rlm_ldap lockout
Arran Cudbard-Bell [Tue, 6 Aug 2013 11:27:16 +0000 (12:27 +0100)]
Fix logic error in rlm_ldap lockout

10 years agoRevert "Attribute 0 is forbidden"
Alan T. DeKok [Tue, 6 Aug 2013 20:45:50 +0000 (16:45 -0400)]
Revert "Attribute 0 is forbidden"

This reverts commit d5b6011a6ffb27c48a12b694bb9cfcfc0f7c5466.

10 years agoOh well
Alan T. DeKok [Tue, 6 Aug 2013 20:45:35 +0000 (16:45 -0400)]
Oh well

Revert "Attribute codes of zero are forbidden"

This reverts commit 12da0d625f0bd5f35c6887e9050eeb189329ca27.

10 years agoAttribute 0 is forbidden
Alan T. DeKok [Tue, 6 Aug 2013 20:44:42 +0000 (16:44 -0400)]
Attribute 0 is forbidden

10 years agoAttribute codes of zero are forbidden
Alan T. DeKok [Tue, 6 Aug 2013 20:12:58 +0000 (16:12 -0400)]
Attribute codes of zero are forbidden

10 years agoThese guys are winners.
Alan T. DeKok [Tue, 6 Aug 2013 20:12:44 +0000 (16:12 -0400)]
These guys are winners.
 Please enter the commit message for your changes. Lines starting

10 years agoBroadsoft dictionary
Alan T. DeKok [Tue, 6 Aug 2013 20:10:19 +0000 (16:10 -0400)]
Broadsoft dictionary

10 years agoDoing nothing is a NOOP
Alan T. DeKok [Tue, 6 Aug 2013 15:31:30 +0000 (11:31 -0400)]
Doing nothing is a NOOP

10 years agoAccounting-Requests don't need User-Name
Alan T. DeKok [Tue, 6 Aug 2013 14:25:11 +0000 (10:25 -0400)]
Accounting-Requests don't need User-Name

10 years agoRemove unused assignments
Alan T. DeKok [Fri, 2 Aug 2013 12:28:17 +0000 (08:28 -0400)]
Remove unused assignments

10 years agoOtherattr should return false by default, so that the check attribute is searched for
Arran Cudbard-Bell [Fri, 2 Aug 2013 10:30:59 +0000 (11:30 +0100)]
Otherattr should return false by default, so that the check attribute is searched for

10 years agoUse the same const order everywhere
Arran Cudbard-Bell [Tue, 30 Jul 2013 22:53:58 +0000 (23:53 +0100)]
Use the same const order everywhere

10 years agore-enable option to disable shared libraries (which causes binaries to be statically...
Arran Cudbard-Bell [Tue, 30 Jul 2013 11:43:56 +0000 (12:43 +0100)]
re-enable option to disable shared libraries (which causes binaries to be statically linked against internal libraries)

10 years agoTypo in libtool.mk
Arran Cudbard-Bell [Tue, 30 Jul 2013 11:35:28 +0000 (12:35 +0100)]
Typo in libtool.mk