Uploading files to scripts from Portal hangs at waiting for feedback

Uploading files to scripts from Portal hangs at waiting for feedback

avatar

Related to the issue in Issues with scripts that take files as input and run as gMSA - Devolutions Forum I have a role required to run the script, if my coworker who only has "MyRole", they can start the script and upload it, but in the admin console the job sits at "Awaiting user feedback". Opening the job reveals that it is expecting File (as a string).

Considering it works for me as an Administrator, but not for the user who only has MyRole, I assume it's some kind of permissions related issue, but I don't think it should be? Correct me if I'm wrong.

Details are the same as before, my running environment is:

OS: Windows Server 2022
PowerShell Universal: Version 2026.2.5
PSU runs as a Windows Service as LocalSystem


Script is:

#.universal\scripts.ps1 (Sanitized):

New-PSUScript -Name 'Test.ps1' -Description 'Test' -Path 'Test.ps1' -Environment 'PowerShell 7' -Credential 'MyGmsaAccount' -Role @('MyRole') -PortalOutputType 'Text' -Icon 'alert' -DisplayOutputOnExecute -ExecutionRole @('MyRole') 

# Script contents
Param(
    [ComponentModel.DisplayName("Upload File")]
    [File]$File
)
'Filename is {0}' -f $File.FileName

Set-Content -Path 'C:\test.xlsx' -AsByteStream -Value $File.Content


The role they're using is this specific one:

New-PSURole -Name "MyRole" -ClaimType "http://schemas.microsoft.com/ws/2008/06/identity/claims/groups" -ClaimValue "MyRole" 

All Comments (1)

avatar

Hello @tholabrk

Thank you for the detailed report and for including the sanitized configuration.

The Administrator versus MyRole difference is particularly useful here. Since the user can select the file and start the script, but the resulting job remains at “Awaiting user feedback,” I would like to isolate whether this behavior is related specifically to the file parameter handling or to the execution context created by the Run As credential and ExecutionRole.

Could you please confirm whether `MyGmsaAccount` has any role restrictions configured?

If possible, could you also test the same script with the MyRole user after temporarily removing both `-Credential 'MyGmsaAccount'` and `-ExecutionRole @('MyRole')`? This would help determine whether the `[File]` parameter works correctly for the restricted user before the Run As execution context is introduced.

I will also review this behavior against PSU 2026.2.5, including the relationship with your previous file upload/gMSA report.

Best regards,
Ruben Tapia