-
Notifications
You must be signed in to change notification settings - Fork 105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ping doesn't work as /bin/ping is not SUID #226
Comments
Hmm, bizarre. Maybe something odd about my install. I didn't do apt upgrade (tho don't know if wlinux-setup does this?). |
I will leave open for now, see if other reports come in, and try to reproduce on 1.1.26. |
Hi everyone: |
I could reproduce it in the same Windows 10 and WLinux versions. In fact after issuing |
I mean we can add something to the rootfs script creation just to make sure the setuid bit is set, which would fix it, but understanding why is definitely something I'm going to work towards figuring out. |
Describe the bug
Ping operations (e.g.
ping localhost
) fail with the errorping: socket: Operation not permitted
.The command does work when run with root privilege (e.g.
sudo ping localhost
).This particular issue should have been resolved since the Creator's Update (see, e.g. microsoft/WSL#18), and does not exhibit in a fresh install of the Ubuntu WSL distro (I am running Windows 10 1809 release)
In comparing
/bin/ping
in WLinux and Ubuntu (18.04) WSL distros, it seems myping
in WLinux does not have the SUID bit:WLinux
/bin/ping
-rwxr-xr-x 1 root root 64K Aug 3 17:53 /bin/ping
Ubuntu 18.04
/bin/ping
-rwsr-xr-x 1 root root 63K Mar 9 2017 /bin/ping
To Reproduce
Steps to reproduce the behavior:
ping
an addressping: socket: Operation not permitted
sudo
, observe successchmod u+s /bin/ping
, repeat ping without root and observe successExpected behavior
/bin/ping
should have the SUID bit (u+s
) set, so that ping operations without root privilege should work without error.Basic Troubleshooting Checklist
[X] I have searched Google for the error message.
[X] I have checked official WSL troubleshooting documentation: https://docs.microsoft.com/en-us/windows/wsl/troubleshooting#confirm-wsl-is-enabled.
[X] I have searched the official Microsoft WSL issues page: https://github.com/Microsoft/WSL/issues.
[X] I have searched the WLinux issues page: https://github.com/WhitewaterFoundry/WLinux/issues.
[X] I have reset WLinux: Settings->Apps->Apps & features->WLinux->Advanced Options->Reset.
[ ] I have disabled and re-enabled WSL in Windows Features.
[X] I have run Windows 10 updates and restarted.
What other troubleshooting have you attempted?
I ran
chmod u+s
on/bin/ping
in WLinux, and now it works as expected.WLinux Version
1.1.25.0
Windows Build
OS Name: Microsoft Windows 10 Pro
OS Version: 10.0.17763 N/A Build 17763
OS Manufacturer: Microsoft Corporation
OS Configuration: Standalone Workstation
OS Build Type: Multiprocessor Free
BIOS Version: Dell Inc. 1.5.1, 09/08/2018
The text was updated successfully, but these errors were encountered: