Skip to content

Instantly share code, notes, and snippets.

@bpsib
Created February 3, 2019 18:26
Show Gist options
  • Select an option

  • Save bpsib/a456a5552944a5938fc49287ad42d05c to your computer and use it in GitHub Desktop.

Select an option

Save bpsib/a456a5552944a5938fc49287ad42d05c to your computer and use it in GitHub Desktop.

Revisions

  1. bpsib created this gist Feb 3, 2019.
    39 changes: 39 additions & 0 deletions cmd.exe.strace
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,39 @@
    1304 execve("/mnt/c/Windows/System32/cmd.exe", ["cmd.exe"], 0x7fffc4c364a8 /* 18 vars */) = 0
    1304 arch_prctl(ARCH_SET_FS, 0x61c0b8) = 0
    1304 set_tid_address(0x61c0f0) = 1304
    1304 getpid() = 1304
    1304 getcwd("/mnt/y", 4096) = 7
    1304 uname({sysname="Linux", nodename="DESKTOP-HP", ...}) = 0
    1304 open("/dev/lxssclient", O_RDWR) = 3
    1304 ioctl(3, _IOC(0, 0, 0x2f, 0x22), 0x7fffd4f6c950) = 0
    1304 open("/mnt/c/Windows/System32/cmd.exe", O_RDONLY|O_NOFOLLOW|O_PATH) = 5
    1304 brk(NULL) = 0xd04000
    1304 brk(0xd05000) = 0xd05000
    1304 ioctl(3, _IOC(0, 0, 0x3f, 0x22), 0x7fffd4f6c7c0) = 0
    1304 close(5) = 0
    1304 open("/mnt/y", O_RDONLY|O_DIRECTORY) = 5
    1304 ioctl(3, _IOC(0, 0, 0x3f, 0x22), 0x7fffd4f6c7c0) = 0
    1304 close(5) = 0
    1304 ioctl(0, TCGETS, {B38400 opost isig icanon echo ...}) = 0
    1304 ioctl(1, TCGETS, {B38400 opost isig icanon echo ...}) = 0
    1304 ioctl(2, TCGETS, {B38400 opost isig icanon echo ...}) = 0
    1304 ioctl(0, TIOCGPGRP, [1302]) = 0
    1304 getpgid(0) = 1302
    1304 fstat(0, {st_mode=S_IFCHR|0660, st_rdev=makedev(4, 1), ...}) = 0
    1304 fstat(1, {st_mode=S_IFCHR|0660, st_rdev=makedev(4, 1), ...}) = 0
    1304 fstat(2, {st_mode=S_IFCHR|0660, st_rdev=makedev(4, 1), ...}) = 0
    1304 ioctl(0, TIOCGWINSZ, {ws_row=30, ws_col=120, ws_xpixel=0, ws_ypixel=0}) = 0
    1304 ioctl(0, SNDCTL_TMR_START or TCSETS, {B38400 -opost -isig -icanon -echo ...}) = 0
    1304 dup(0) = 5
    1304 ioctl(4, _IOC(0, 0, 0xb7, 0x22), 0x7fffd4f6c920) = 0
    1304 ioctl(4, _IOC(0, 0, 0xb7, 0x22), 0x7fffd4f6c920) = 0
    1304 ioctl(4, _IOC(0, 0, 0xb7, 0x22), 0x7fffd4f6c920) = 0
    1304 write(4, "\0\0\0\0\255\0\0\0\217\0\0\0\0\0\0\0\220\0\0\0\0\0\0\0\221\0\0\0\0\0\0\0"..., 173) = 173
    1304 read(4, "\10\0\0\0000\0\0\0\26\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 48) = 48
    1304 writev(2, [{iov_base="/mnt/c/Windows/System32/cmd.exe:"..., iov_len=50}, {iov_base=NULL, iov_len=0}], 2) = 50
    1304 close(3) = 0
    1304 close(4) = 0
    1304 ioctl(5, SNDCTL_TMR_START or TCSETS, {B38400 opost isig icanon echo ...}) = 0
    1304 close(5) = 0
    1304 exit_group(1) = ?
    1304 +++ exited with 1 +++