Powershell And Jar Execution : **I a trying to execute a jar file from powershell from a remote powershell session. Below is my current script block and it does not seem to work on remote machine. It appears that the jar file is picking up an anonymous credential but if i put a username command before the jar i get the actual user.**

    Invoke-Command -ComputerName "servera" -Credential $global:credential -ScriptBlock { java -cp "multiplejars" main "arguments"}

This is my current error.
**caused by: liquibase.exception.DatabaseException: com.microsoft.sqlserver.jdbc.SQLServerException: Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'. ClientConnectionId:7071e2b2-b
ad9-48db-b01a-d86665c783ff**