The FreeRADIUS server  $Id: 15bac2a4c627c01d1aa2047687b3418955ac7f00 $
Functions
tmpl.c File Reference

Defines functions for calling tmpl__t asynchronously. More...

#include <freeradius-devel/unlang/tmpl.h>
#include <freeradius-devel/server/exec.h>
#include <freeradius-devel/util/syserror.h>
#include <freeradius-devel/util/value.h>
#include "tmpl_priv.h"
#include <signal.h>
+ Include dependency graph for tmpl.c:

Go to the source code of this file.

Functions

static unlang_action_t unlang_tmpl (rlm_rcode_t *p_result, request_t *request, unlang_stack_frame_t *frame)
 
static unlang_action_t unlang_tmpl_exec_wait_final (rlm_rcode_t *p_result, request_t *request, unlang_stack_frame_t *frame)
 Wrapper to call exec after the program has finished executing. More...
 
static unlang_action_t unlang_tmpl_exec_wait_resume (rlm_rcode_t *p_result, request_t *request, unlang_stack_frame_t *frame)
 Wrapper to call exec after a tmpl has been expanded. More...
 
void unlang_tmpl_init (void)
 
int unlang_tmpl_push (TALLOC_CTX *ctx, fr_value_box_list_t *out, request_t *request, tmpl_t const *tmpl, unlang_tmpl_args_t *args)
 Push a tmpl onto the stack for evaluation. More...
 
static unlang_action_t unlang_tmpl_resume (rlm_rcode_t *p_result, request_t *request, unlang_stack_frame_t *frame)
 Wrapper to call a resumption function after a tmpl has been expanded. More...
 
static void unlang_tmpl_signal (request_t *request, unlang_stack_frame_t *frame, fr_signal_t action)
 Send a signal (usually stop) to a request. More...
 

Detailed Description

Defines functions for calling tmpl__t asynchronously.

Id
fe96e217544536ddee8dae8895e2475d132c559d

Definition in file tmpl.c.

Function Documentation

◆ unlang_tmpl()

static unlang_action_t unlang_tmpl ( rlm_rcode_t p_result,
request_t request,
unlang_stack_frame_t frame 
)
static

Definition at line 194 of file tmpl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ unlang_tmpl_exec_wait_final()

static unlang_action_t unlang_tmpl_exec_wait_final ( rlm_rcode_t p_result,
request_t request,
unlang_stack_frame_t frame 
)
static

Wrapper to call exec after the program has finished executing.

Definition at line 100 of file tmpl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ unlang_tmpl_exec_wait_resume()

static unlang_action_t unlang_tmpl_exec_wait_resume ( rlm_rcode_t p_result,
request_t request,
unlang_stack_frame_t frame 
)
static

Wrapper to call exec after a tmpl has been expanded.

Definition at line 171 of file tmpl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ unlang_tmpl_init()

void unlang_tmpl_init ( void  )

Definition at line 327 of file tmpl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ unlang_tmpl_push()

int unlang_tmpl_push ( TALLOC_CTX *  ctx,
fr_value_box_list_t *  out,
request_t request,
tmpl_t const *  tmpl,
unlang_tmpl_args_t args 
)

Push a tmpl onto the stack for evaluation.

Parameters
[in]ctxTo allocate value boxes and values in.
[out]outThe value_box created from the tmpl. May be NULL, in which case the result is discarded.
[in]requestThe current request.
[in]tmplthe tmpl to expand
[in]argsadditional controls for expanding TMPL_TYPE_EXEC, and where the status of exited programs will be stored.

Definition at line 259 of file tmpl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ unlang_tmpl_resume()

static unlang_action_t unlang_tmpl_resume ( rlm_rcode_t p_result,
request_t request,
unlang_stack_frame_t frame 
)
static

Wrapper to call a resumption function after a tmpl has been expanded.

If the resumption function returns YIELD, then this function is called repeatedly until the resumption function returns a final value.

Definition at line 77 of file tmpl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ unlang_tmpl_signal()

static void unlang_tmpl_signal ( request_t request,
unlang_stack_frame_t frame,
fr_signal_t  action 
)
static

Send a signal (usually stop) to a request.

This is typically called via an "async" action, i.e. an action outside of the normal processing of the request.

If there is no fr_unlang_tmpl_signal_t callback defined, the action is ignored.

Parameters
[in]requestThe current request.
[in]framebeing signalled.
[in]actionto signal.

Definition at line 50 of file tmpl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function: