PSM Web application shows injectPortBlockToProcess error

PSM Web application shows injectPortBlockToProcess error

217
Created On 11/10/26 11:00 AM - Last Modified 11/10/26 16:05 PM


Symptom


PSM-WebApp connection returned injectPortBlockToProcess error
image.png

In the PSM component dispatcher log:

Scenario 1
[01/11/2022 | 22:17:12] | :: | PSMDU001I PSM Dispatcher Utils exception occurred. PSMDU051E DLLInjector error, exited with code: 1. (Codes: -1, -1)
[01/11/2022 | 22:17:12] | :: | PSMDU015E Error performing process hook [HookPortBlockToProcess]. Reason: PSMDU051E DLLInjector error, exited with code: 1
[01/11/2022 | 22:17:12] | :: | PSMDU019I Dispatcher trace message: [ProgressBarHandler :: Close -> START] [01/11/2022 | 22:17:12] | :: | PSMDU019I Dispatcher trace message: [ProgressBarHandler :: Close -> END] [01/11/2022 | 22:17:12] | :: | PSMDU018E Dispatcher error: [WebFormDispatcher :: HandleException -> CyberArk.PSM.WebAppDispatcher.Exceptions.WebAppDispatcherPSMDispatcherUtilsException: Function InjectPortBlockToProcess returned with an error. at CyberArk.PSM.WebAppDispatcher.WebFormDispatcher.InitBrowser(IWindow winUtils, IExecuter executer) at CyberArk.PSM.WebAppDispatcher.WebFormDispatcher.ExecuteLogin(IExecuter actionExecuter)]
 

Scenario 2
[20/01/2023 | 03:23:56] | :: | PSMDU001I PSM Dispatcher Utils exception occurred. PSMDU051E DLLInjector error, exited with code: -1073741515. (Codes: -1, -1)
[20/01/2023 | 03:23:56] | :: | PSMDU015E Error performing process hook [HookPortBlockToProcess]. Reason: PSMDU051E DLLInjector error, exited with code: -1073741515.
[20/01/2023 | 03:23:56] | :: | PSMDU019I Dispatcher trace message: [ProgressBarHandler :: Close -> START]
[20/01/2023 | 03:23:56] | :: | PSMDU019I Dispatcher trace message: [ProgressBarHandler :: Close -> END]
[20/01/2023 | 03:23:57] | :: | PSMDU018E Dispatcher error: [WebFormDispatcher :: HandleException -> CyberArk.PSM.WebAppDispatcher.Exceptions.WebAppDispatcherPSMDispatcherUtilsException: Function InjectPortBlockToProcess returned with an error. at CyberArk.PSM.WebAppDispatcher.WebFormDispatcher.InitBrowser(IWindow winUtils, IExecuter executer) at CyberArk.PSM.WebAppDispatcher.WebFormDispatcher.ExecuteLogin(IExecuter actionExecuter)]
[20/01/2023 | 03:23:57] | :: | PSMDU019I Dispatcher trace message: [ConnectionComponentController :: PopUpErrorMessageBox -> START]
[20/01/2023 | 03:23:57] | :: | PSMDU018E Dispatcher error: [ConnectionComponentController :: PopUpErrorMessageBox -> Title="Error Occurred" Message="Function InjectPortBlockToProcess returned with an error.." Timeout=30 Subtitle="Login failed"]
 

NOTE:
"There is also a possibility that you will encounter this issue when upgrading PSM. And even though there is a C++ redistributable DLL already installed, the upgraded PSM requires the latest version of C++ redistributable DLL"


Environment


12.1;12.2;12.6;12.7;13.0 Privilege Cloud PSM
  • PSM Connection via PVWA
  • PSM
  • Chrome
  • Visual C++ Redistributable


Cause


Scenario 1
The chrome driver does match the Chrome version.
Chrome browser has been updated automatically but Chrome driver requires manual upgrade

Scenario 2
Possible missing DLLs if exit code -1073741515 is seen for DLLInjector. In most cases related to Visual C++ Redistributable DLLs. Either not installed or not on latest version.


Resolution


Scenario 1
  1. Download the chrome driver in the same version as the Chrome browser installed on PSM https://chromedriver.chromium.org/downloads or https://googlechromelabs.github.io/chrome-for-testing/#stable (Note: If the exact driver build is not listed, the latest major version "typically" succeeds e.g. Chrome build 119.0.6045.200 vs. file version 119.0.6045.105)
  2. Copy the chrome driver to the PSM components folder, the default path is 'C:\Program Files (x86)\CyberArk\PSM\Components'
  3. Re-run PSMConfigureAppLocker.ps1
Note: If the above doesn't work and you also see the same injectPortBlockToProcess error using both Chrome and Edge, we've seen cases where AV has quarantined some PSM files when the PSM folder is not properly excluded from the AV. For example "MinHook.x86.dll" within the components folder being quarantined can cause the log errors we see in Scenario 1. In this case a repair or upgrade/patch of the PSM can resolve it.

Scenario 2
  • Using Procmon to identify which DLL(s) had failed to load by comparing with the working one.
  • Set procmon filter for Process Name and User
  • image.png
  • Compare the logs
  • procmon analysis result.png
  • Fix the missing/denied DLLs. (In this example, the Visual C++ Redistributable package is not installed.)
  • Install the missing or latest Visual C++ Redistributable package


Actions
  • Print
  • Copy Link

    https://knowledgebase.paloaltonetworks.com/KCSArticleDetail?id=kA1hj0000001KxiCAE&lang=en_US&refURL=http%3A%2F%2Fknowledgebase.paloaltonetworks.com%2FKCSArticleDetail