http://swpat.ffii.org/
Action against software patents
http://www.gnome.org/
Gnome2 Logo
http://www.w3.org/Status
W3C logo
http://www.redhat.com
Red Hat Logo
http://xmlsoft.org/XSLT/
Made with Libxslt Logo
The XSLT C library for Gnome
Module security from libxslt
API Menu
../index.html
Main Menu
../docs.html
Developer Menu
index.html
API Menu
../ChangeLog.html
ChangeLog
Related links
http://mail.gnome.org/archives/xslt/
Mail archive
http://xmlsoft.org/
XML libxml2
ftp://xmlsoft.org/
FTP
http://www.zlatkovic.com/projects/libxml/
Windows binaries
http://garypennington.net/libxml2/
Solaris binaries
http://www.zveno.com/open_source/libxml2xslt.html
MacOsX binaries
http://bugzilla.gnome.org/buglist.cgi?product=libxslt
Bug Tracker
http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17
XSLT with PHP
http://www.mod-xslt2.com/
Apache module
http://sourceforge.net/projects/libxml2-pas/
Pascal bindings
http://xsldbg.sourceforge.net/
Xsldbg Debugger
API Indexes
../APIchunk0.html
Alphabetic
../APIconstructors.html
Constructors
../APIfunctions.html
Functions/Types
../APIfiles.html
Modules
../APIsymbols.html
Symbols
libxslt-preproc.html
Prev
libxslt-preproc.html
preproc
index.html
Up
index.html
API documentation
../index.html
Home
../index.html
Home
libxslt-templates.html
templates
libxslt-templates.html
Next
the libxslt security framework allow to restrict the access to new resources (file or URL) from the stylesheet at runtime.
Table of Contents
Enum
#xsltSecurityOption
xsltSecurityOption
Structure
#xsltSecurityPrefs
xsltSecurityPrefs
struct _xsltSecurityPrefs
The content of this structure is not made public by the API.
Typedef
libxslt-security.html#xsltSecurityPrefs
xsltSecurityPrefs
*
xsltSecurityPrefsPtr
int
#xsltCheckRead
xsltCheckRead
(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt,
const xmlChar * URL)
int
#xsltCheckWrite
xsltCheckWrite
(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt,
const xmlChar * URL)
void
#xsltFreeSecurityPrefs
xsltFreeSecurityPrefs
(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec)
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
#xsltGetDefaultSecurityPrefs
xsltGetDefaultSecurityPrefs
(void)
libxslt-security.html#xsltSecurityCheck
xsltSecurityCheck
#xsltGetSecurityPrefs
xsltGetSecurityPrefs
(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-security.html#xsltSecurityOption
xsltSecurityOption
option)
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
#xsltNewSecurityPrefs
xsltNewSecurityPrefs
(void)
int
#xsltSecurityAllow
xsltSecurityAllow
(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt,
const char * value)
Function type:
#xsltSecurityCheck
xsltSecurityCheck
int
#xsltSecurityCheck
xsltSecurityCheck
(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt,
const char * value)
int
#xsltSecurityForbid
xsltSecurityForbid
(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt,
const char * value)
int
#xsltSetCtxtSecurityPrefs
xsltSetCtxtSecurityPrefs
(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt)
void
#xsltSetDefaultSecurityPrefs
xsltSetDefaultSecurityPrefs
(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec)
int
#xsltSetSecurityPrefs
xsltSetSecurityPrefs
(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-security.html#xsltSecurityOption
xsltSecurityOption
option,
libxslt-security.html#xsltSecurityCheck
xsltSecurityCheck
func)
Description
Enum
xsltSecurityOption
Enum xsltSecurityOption {
XSLT_SECPREF_READ_FILE
= 1
XSLT_SECPREF_WRITE_FILE
= 2
XSLT_SECPREF_CREATE_DIRECTORY
= 3
XSLT_SECPREF_READ_NETWORK
= 4
XSLT_SECPREF_WRITE_NETWORK
= 5
}
Structure xsltSecurityPrefs
Structure xsltSecurityPrefs
struct _xsltSecurityPrefs {
The content of this structure is not made public by the API.
}
Function: xsltCheckRead
int	xsltCheckRead			(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt,
const xmlChar * URL)
Check if the resource is allowed to be read
sec
:
the security options
ctxt
:
an XSLT transformation context
URL
:
the resource to be read
Returns
:
1 if read is allowed, 0 if not and -1 in case or error.
Function: xsltCheckWrite
int	xsltCheckWrite			(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt,
const xmlChar * URL)
Check if the resource is allowed to be written, if necessary makes some preliminary work like creating directories
sec
:
the security options
ctxt
:
an XSLT transformation context
URL
:
the resource to be written
Returns
:
1 if write is allowed, 0 if not and -1 in case or error.
Function: xsltFreeSecurityPrefs
void	xsltFreeSecurityPrefs		(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec)
Free up a security preference block
sec
:
the security block to free
Function: xsltGetDefaultSecurityPrefs
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
xsltGetDefaultSecurityPrefs	(void)
Get the default security preference application-wide
Returns
:
the current
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
in use or NULL if none
Function: xsltGetSecurityPrefs
libxslt-security.html#xsltSecurityCheck
xsltSecurityCheck
xsltGetSecurityPrefs	(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-security.html#xsltSecurityOption
xsltSecurityOption
option)
Lookup the security option to get the callback checking function
sec
:
the security block to update
option
:
the option to lookup
Returns
:
NULL if not found, the function otherwise
Function: xsltNewSecurityPrefs
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
xsltNewSecurityPrefs	(void)
Create a new security preference block
Returns
:
a pointer to the new block or NULL in case of error
Function: xsltSecurityAllow
int	xsltSecurityAllow		(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt,
const char * value)
Function used to always allow an operation
sec
:
the security block to use
ctxt
:
an XSLT transformation context
value
:
unused
Returns
:
1 always
Function type: xsltSecurityCheck
Function type: xsltSecurityCheck
int	xsltSecurityCheck		(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt,
const char * value)
User provided function to check the value of a string like a file path or an URL ...
sec
:
ctxt
:
value
:
Returns
:
Function: xsltSecurityForbid
int	xsltSecurityForbid		(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt,
const char * value)
Function used to always forbid an operation
sec
:
the security block to use
ctxt
:
an XSLT transformation context
value
:
unused
Returns
:
0 always
Function: xsltSetCtxtSecurityPrefs
int	xsltSetCtxtSecurityPrefs	(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-xsltInternals.html#xsltTransformContextPtr
xsltTransformContextPtr
ctxt)
Set the security preference for a specific transformation
sec
:
the security block to use
ctxt
:
an XSLT transformation context
Returns
:
-1 in case of error, 0 otherwise
Function: xsltSetDefaultSecurityPrefs
void	xsltSetDefaultSecurityPrefs	(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec)
Set the default security preference application-wide
sec
:
the security block to use
Function: xsltSetSecurityPrefs
int	xsltSetSecurityPrefs		(
libxslt-security.html#xsltSecurityPrefsPtr
xsltSecurityPrefsPtr
sec,
libxslt-security.html#xsltSecurityOption
xsltSecurityOption
option,
libxslt-security.html#xsltSecurityCheck
xsltSecurityCheck
func)
Update the security option to use the new callback checking function
sec
:
the security block to update
option
:
the option to update
func
:
the user callback to use for this option
Returns
:
-1 in case of error, 0 otherwise
../bugs.html
Daniel Veillard
