Custom config via /etc/apache2/imscp/[domain.com].conf or .htaccess not working

  • Hi folks,


    I am trying to disable HTTP OPTIONS for security reasons in i-MSCP 1.3.16 (Build: 20170107).


    Short explanation:


    If I drop a


    Code
    1. # curl -i -X OPTIONS http://139.1.x.xHTTP/1.1 200 OKDate: Fri, 05 May 2017 10:25:16 GMTServer: ApacheStrict-Transport-Security: max-age=31536000; includeSubDomainX-Frame-Options: sameoriginX-Content-Type-Options: nosniffAllow: GET,HEAD,POST,OPTIONSX-Frame-Options: sameoriginContent-Length: 0Content-Type: text/html


    The "Allow" for OPTIONS should not be displayed.


    So I added the following lines to /etc/apache2/imscp/mydomain.com.conf


    Code
    1. RewriteEngine
    2. OnRewriteCond %{REQUEST_METHOD} !^(GET|POST|HEAD)
    3. RewriteRule .* - [R=405,L]


    and reloaded my Apache.


    Additionally, I added a .htaccess with the same content in my document root.


    Noting changed so far.


    Any help would be appreciated. Thanx !
    BG

  • OnRewriteCond

    ?(

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • Pardon ?
    Could you please be more specific ?

    There is not such OnRewriteCond directive

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206