Blame apache2/msc_pcre.h

Packit 284210
/*
Packit 284210
* ModSecurity for Apache 2.x, http://www.modsecurity.org/
Packit 284210
* Copyright (c) 2004-2013 Trustwave Holdings, Inc. (http://www.trustwave.com/)
Packit 284210
*
Packit 284210
* You may not use this file except in compliance with
Packit 284210
* the License.  You may obtain a copy of the License at
Packit 284210
*
Packit 284210
*     http://www.apache.org/licenses/LICENSE-2.0
Packit 284210
*
Packit 284210
* If any of the files related to licensing are missing or if you have any
Packit 284210
* other questions related to licensing please contact Trustwave Holdings, Inc.
Packit 284210
* directly using the email address security@modsecurity.org.
Packit 284210
*/
Packit 284210
Packit 284210
#ifndef _MSC_PCRE_H_
Packit 284210
#define _MSC_PCRE_H_
Packit 284210
Packit 284210
typedef struct msc_regex_t msc_regex_t;
Packit 284210
Packit 284210
#include "pcre.h"
Packit 284210
Packit 284210
#ifndef PCRE_ERROR_MATCHLIMIT
Packit 284210
/* Define for compile, but not valid in this version of PCRE. */
Packit 284210
#define PCRE_ERROR_MATCHLIMIT (-8)
Packit 284210
#endif /* PCRE_ERROR_MATCHLIMIT */
Packit 284210
Packit 284210
#ifndef PCRE_ERROR_RECURSIONLIMIT
Packit 284210
/* Define for compile, but not valid in this version of PCRE. */
Packit 284210
#define PCRE_ERROR_RECURSIONLIMIT (-21)
Packit 284210
#endif /* PCRE_ERROR_RECURSIONLIMIT */
Packit 284210
Packit 284210
#include "apr_general.h"
Packit 284210
#include "modsecurity.h"
Packit 284210
Packit 284210
struct msc_regex_t {
Packit 284210
    void            *re;
Packit 284210
    void            *pe;
Packit 284210
    const char      *pattern;
Packit 284210
};
Packit 284210
Packit 284210
void DSOLOCAL *msc_pregcomp_ex(apr_pool_t *pool, const char *pattern, int options,
Packit 284210
                               const char **_errptr, int *_erroffset,
Packit 284210
                               int match_limit, int match_limit_recursion);
Packit 284210
Packit 284210
void DSOLOCAL *msc_pregcomp(apr_pool_t *pool, const char *pattern, int options,
Packit 284210
                            const char **_errptr, int *_erroffset);
Packit 284210
Packit 284210
int DSOLOCAL msc_regexec_ex(msc_regex_t *regex, const char *s,
Packit 284210
                            unsigned int slen, int startoffset, int options,
Packit 284210
                            int *ovector, int ovecsize, char **error_msg);
Packit 284210
Packit 284210
int DSOLOCAL msc_regexec_capture(msc_regex_t *regex, const char *s,
Packit 284210
                                 unsigned int slen, int *ovector,
Packit 284210
                                 int ovecsize, char **error_msg);
Packit 284210
Packit 284210
int DSOLOCAL msc_regexec(msc_regex_t *regex, const char *s,
Packit 284210
                         unsigned int slen, char **error_msg);
Packit 284210
Packit 284210
int DSOLOCAL msc_fullinfo(msc_regex_t *regex, int what, void *where);
Packit 284210
Packit 284210
#endif