Removing X-Powered-By-Plesk: PleskWin

Discussion in 'Plesk 11.x for Windows' started by Chuck Verc, Mar 25, 2014.

  1. Chuck Verc

    Chuck Verc New Pleskian

    20
     
    Joined:
    Apr 22, 2009
    Messages:
    20
    Likes Received:
    0
    Hi,
    does anyone know of to get ride of <X-Powered-By-Plesk: PleskWin> header that is added by plesk ?

    I know I can access IIS and remove it on a domain by domain basis but since it's not listed in the IIS default Headers, I don't know how to remove it for every domains (new and old)

    Thanks

    edit: Using Plesk 11 latest updates on Windows 2012 server fully updated as well
     
    Last edited: Mar 25, 2014
  2. IgorG

    IgorG Forums Analyst Plesk Team

    43
    84%
    Joined:
    Oct 27, 2009
    Messages:
    22,949
    Likes Received:
    755
    Location:
    Novosibirsk, Russia
    Adding this header is hardcoded in websrvmng.
    You can try to use utility AppCmd for IIS for removing this headed for old domains and use it as command for Event Manager for domain creation event.
     
  3. ChueFlade

    ChueFlade New Pleskian

    7
    70%
    Joined:
    Apr 9, 2014
    Messages:
    10
    Likes Received:
    0
    Open the following file in your favourite text editor with administrator permissions:
    Then search for "X-Powered-By-Plesk" and remove the related XML elements.

    Hope this helps...
     
  4. Alex Laforge

    Alex Laforge New Pleskian

    4
    20%
    Joined:
    Feb 8, 2017
    Messages:
    9
    Likes Received:
    1
    Location:
    Paris
    If you want this "X-Powered-By-Plesk" Header to be removed from EVERY NEWLY created domains, you can create a default web.config file within the "httpdocs" folder of the "Default Host Template". This default website template is usually located under : "C:\inetpub\vhosts\.skel\0\httpdocs".
    That web.config file will be used by default when you create a new website.

    <?xml version="1.0" encoding="UTF-8"?>
    <configuration>
    <system.webServer>
    <httpProtocol>
    <customHeaders>
    <remove name="X-Powered-By-Plesk" />
    </customHeaders>
    </httpProtocol>
    </system.webServer>
    </configuration>



    PS: Additionally, you can use this default web.config file to set all configuration parameters you want to use for every new website (in example : to define a list of default documents for your websites, as explained on this Plesk Help article : https://support.plesk.com/hc/en-us/...-default-document-settings-in-Parallels-Plesk )
     
  5. Alex Laforge

    Alex Laforge New Pleskian

    4
    20%
    Joined:
    Feb 8, 2017
    Messages:
    9
    Likes Received:
    1
    Location:
    Paris
    Hi IgorG, how would I listen for "Event Manager for domain creation event" ? I would need to run a specific PowerShell or VbScript file to perform some customizations to the newly created website (not possible with template files).
    Is that in the Windows Event Viewer ? I've never done such a thing... Thank you for you starting point and any clue ;)
     
  6. IgorG

    IgorG Forums Analyst Plesk Team

    43
    84%
    Joined:
    Oct 27, 2009
    Messages:
    22,949
    Likes Received:
    755
    Location:
    Novosibirsk, Russia
    No, I meant Plesk Event manager. (Tools & Settings -> Event Manager)
     
  7. Alex Laforge

    Alex Laforge New Pleskian

    4
    20%
    Joined:
    Feb 8, 2017
    Messages:
    9
    Likes Received:
    1
    Location:
    Paris
Loading...