App Control: Unable to Locally Approve Files from Events or File Catalog
search cancel

App Control: Unable to Locally Approve Files from Events or File Catalog

book

Article ID: 291222

calendar_today

Updated On:

Products

Carbon Black App Control (formerly Cb Protection)

Issue/Introduction

  • Unable to approve files locally
  • PHP Error Logs:
    API Error from page 200: PUT ServerName/api/bit9platform/v1/fileCatalog/*******?changeLocalStateForComputerId=???&newApprovalState=2 with params []...
    Returned http code 404

Environment

  • App Control Server (formerly CB Protection): All Supported Versions
  • App Control Console (formerly CB Protection): All Supported Versions

Cause

PUT and DELETE API request not accepted by the server

Resolution

  1. Log in to App Control Server
  2. OpenĀ C:\Program Files (x86)\Bit9\Parity Console\API\
  3. Backup the file 'web.config'
  4. Stop the App Control Server and Reporter Services
  5. Modify the web.config file: replace the whole content in the tag <system.webServer> New Information HERE <system.webServer /> tags
    <validation validateIntegratedModeConfiguration="false" />
    <handlers>
    <remove name="ExtensionlessUrlHandler-ISAPI-4.0_32bit" />
    <remove name="ExtensionlessUrlHandler-ISAPI-4.0_64bit" />
    <remove name="ExtensionlessUrlHandler-Integrated-4.0" />
    
    //This will enable all Web API verbose
    <add name="ExtensionlessUrlHandler-ISAPI-4.0_32bit" path="*." verb="GET,HEAD,POST,DEBUG,PUT,DELETE,PATCH,OPTIONS" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll" preCondition="classicMode,runtimeVersionv4.0,bitness32" responseBufferLimit="0" />
    <add name="ExtensionlessUrlHandler-ISAPI-4.0_64bit" path="*." verb="GET,HEAD,POST,DEBUG,PUT,DELETE,PATCH,OPTIONS" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll" preCondition="classicMode,runtimeVersionv4.0,bitness64" responseBufferLimit="0" />
    <add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="GET,HEAD,POST,DEBUG,PUT,DELETE,PATCH,OPTIONS" type="System.Web.Handlers.TransferRequestHandler" preCondition="integratedMode,runtimeVersionv4.0" />
    </handlers>
    
  6. Restart IIS serverĀ 
  7. Restart the App Control Server and Reporter Service

Additional Information

Entries may need to be added to Web.config file according to this external aricle:https://forums.asp.net/t/1961593.aspx?DELETE+PUT+verbs+result+in+404+Not+Found+in+WebAPI+only+when+running+locally