src/transaction.cc
/**
 * @name    processResponseHeaders
 * @brief   Perform the analysis on the response readers.
 *
 * This method perform the analysis on the response headers, notice however
 * that the headers should be added prior to the execution of this function.
 *
 * @note Remember to check for a possible intervention.
 *
 * @param code The returned http code.
 * @param proto Protocol used on the response.
 * 
 * @returns If the operation was successful or not.
 * @retval true Operation was successful.
 * @retval false Operation failed.
 *
 */
@name    processResponseHeaders
@brief   Perform the analysis on the response readers.

This method perform the analysis on the response headers, notice however
that the headers should be added prior to the execution of this function.

@note Remember to check for a possible intervention.

@param code The returned http code.
@param proto Protocol used on the response.

@returns If the operation was successful or not.
@retval true Operation was successful.
@retval false Operation failed.
@name processResponseHeaders @brief Perform the analysis on the response readers . This method perform the analysis on the response headers notice however that the headers should be added prior to the execution of this function . @note Remember to check for a possible intervention . @param code The returned http code . @param proto Protocol used on the response . @returns If the operation was successful or not . @retval true Operation was successful . @retval false Operation failed .
int Transaction::processResponseHeaders(int code, const std::string& proto) {
#ifndef NO_LOGS
    debug(4, "Starting phase RESPONSE_HEADERS. (SecRules 3)");
#endif
    this->m_httpCodeReturned = code;
    this->m_collections.store("RESPONSE_STATUS", std::to_string(code));
    m_collections.store("RESPONSE_PROTOCOL", proto);
    if (m_rules->m_secRuleEngine == Rules::DisabledRuleEngine) {
#ifndef NO_LOGS
        debug(4, "Rule engine disabled, returning...");
#endif
        return true;
    }
    this->m_rules->evaluate(modsecurity::ResponseHeadersPhase, this);
    return true;
}
int Transaction :: processResponseHeaders ( int code , const std :: string & proto ) { #ifndef NO_LOGS debug ( 4 , " " ) ; #endif this -> m_httpCodeReturned = code ; this -> m_collections . store ( " " , std :: to_string ( code ) ) ; m_collections . store ( " " , proto ) ; if ( m_rules -> m_secRuleEngine == Rules :: DisabledRuleEngine ) { #ifndef NO_LOGS debug ( 4 , " " ) ; #endif return true ; } this -> m_rules -> evaluate ( modsecurity :: ResponseHeadersPhase , this ) ; return true ; }
@name    processResponseHeaders
 @brief   Perform the analysis on the response readers.
@name processResponseHeaders @brief Perform the analysis on the response readers .