1
I have a windows box setup with cygwin and an ssh server that has been working fine, however today I came across a command I am trying to use that returns different results based on whether it is used locally or over ssh.
First we have the results of running it over ssh...
ssh -i /tmp/tmpyEW3f0 Administrator@10.13.7.210 'tasklist /FI "username eq Administrator"'
INFO: No tasks running with the specified criteria.
Now we run the same command locally on 10.13.7.210 and recieve this result...
C:\Documents and Settings\Administrator>tasklist /FI "username eq Administrator"
Image Name PID Session Name Session# Mem Usage
========================= ====== ================ ======== ============
explorer.exe 536 RDP-Tcp#14 0 24,400 K
jusched.exe 776 RDP-Tcp#14 0 9,228 K
ctfmon.exe 780 RDP-Tcp#14 0 3,456 K
ApacheMonitor.exe 796 RDP-Tcp#14 0 2,520 K
rdpclip.exe 444 RDP-Tcp#14 0 4,344 K
jucheck.exe 1160 RDP-Tcp#14 0 8,708 K
cmd.exe 876 RDP-Tcp#14 0 2,852 K
tasklist.exe 3008 RDP-Tcp#14 0 4,292 K
Any idea why these are producing different results?
@EEP I'm having the same problem, did you find a solution or a workaround since? – zovits – 2018-07-27T13:40:11.050
Almost certainly yes, but just to make sure, are you running the command as the same user in the local session? – Costa – 2013-05-16T15:19:45.190
Yes, it is running as the same user in both situations. – EEP – 2013-05-21T18:04:36.800
try with 'CMD /C' before your tasklist command, also run 'whoami' instead of tasklist and see what it says – golimar – 2013-05-23T10:31:40.690