smartctl -a /dev/sdN
fsck
из read-only, через liveCD или single-user mode $ curl -s -A "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:47.0) Gecko/20100101 Firefox 47.0" http://натяжныепотолкиказань.рф | head
<html xmlns="http://www.w3.org/1999/xhtml"><head><meta name="keywords" content="jp"><meta name="Content-Language" content="jp"/>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>【】dunhill L2H647 FACETダンヒル ファセット名刺入レザー ブラック:ブランドショップ ア・ドマーニ</title>
$ curl -s -A "Mozilla/5.0 (Windows; rv:47.0) Gecko/20100101 Firefox 47.0" http://натяжныепотолкиказань.рф | head
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<!--[if lt IE 9]><script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script><![endif]--><title id="5790062915">Натяжные потолки</title>
<meta name="keywords" content="">
<meta name="description" content="">
<link rel="stylesheet" href="jquery.animateSlider.css">
<link rel="stylesheet" href="demo2.css">
<link rel="shortcut icon" href="favicon.png" type="image/png">
setcap 'cap_net_bind_service=+ep' /path/to/program
Now for the caveats:
- You will need at least a 2.6.24 kernel
- This won't work if your file is a script. (ie, uses a #! line to launch an interpreter). In this case, as far I as understand, you'd have to apply the capability to the interpreter executable itself, which of course is a security nightmare, since any program using that interpreter will have the capability. I wasn't able to find any clean, easy way to work around this problem.
- Linux will disable LD_LIBRARY_PATH on any program that has elevated privileges like setcap or suid. So if your program uses its own .../lib/, you might have to look into another option like port forwarding.