Sun Java System Access Manager 7.1 C API Reference


Renders an HTML page based on the result of a web agent's enforcement.


#include "am_web.h"
typedef am_status_t (*am_web_render_result_func_t)
                               (void **args,
                                am_web_result_t http_result,
                                char *data);


This function takes the following parameter:


Pointer to a pointer to agent defined parameters.


One of the following values of the am_web_result_t enumeration as defined:

#include "am_web.h"
typedef enum {
    AM_WEB_RESULT_OK,               /* access check was OK */
    AM_WEB_RESULT_OK_DONE,          /* OK and handled (for ex. notification) */
    AM_WEB_RESULT_FORBIDDEN,        /* access forbidden */
    AM_WEB_RESULT_REDIRECT,         /* redirected */
    AM_WEB_RESULT_ERROR             /* internal error */
} am_web_result_t;

For AM_WEB_RESULT_OK_DONE, the web agent should return an HTTP status code 200 OK and the body of the HTTP response should be set to the string in the data parameter. For AM_WEB_RESULT_REDIRECT, the web agent should return an HTTP status code 302 and the Location header should be set to the redirect URL in the data argument. More information on these request methods can be found in


Pointer to a string defining user data, a URL, or other data.


This function returns one of the following values of the am_status_t enumeration (defined in the <am_types.h> header file):


If page was successfully rendered.


If not successfully freed, the status will be logged as a warning but ignored.