X-Received: by 2002:a37:7a85:: with SMTP id v127mr48925796qkc.373.1608208096676; Thu, 17 Dec 2020 04:28:16 -0800 (PST) X-Received: by 2002:a5b:812:: with SMTP id x18mr60996094ybp.334.1608208096354; Thu, 17 Dec 2020 04:28:16 -0800 (PST) Path: csiph.com!xmission!news.snarked.org!border2.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail Newsgroups: fr.comp.lang.python Date: Thu, 17 Dec 2020 04:28:15 -0800 (PST) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: google-groups.googlegroups.com; posting-host=185.24.186.214; posting-account=dcD-vwoAAAADRTmn7k3Lt-A6Fc1w3JmV NNTP-Posting-Host: 185.24.186.214 References: <756e5489-40b6-4456-8593-19809e097c46n@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: sudo python PermissionError [Errno 13] Permission denied From: "pata...@gmail.com" Injection-Date: Thu, 17 Dec 2020 12:28:16 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Lines: 35 Xref: csiph.com fr.comp.lang.python:3414 Le jeudi 17 d=C3=A9cembre 2020 =C3=A0 12:16:06 UTC+1, yamo' a =C3=A9crit=C2= =A0: > Salut,=20 > x a tapot=C3=A9 le 17/12/2020 10:56: > > pourquoi le super-utilisateur root ne peut-il pas manipuler le fichier = avec Python ? > Tu dois avoir une protection sur /tmp=20 >=20 > /usr/local/bin ou /var/tmp sont peut-=C3=AAtre plus adapt=C3=A9s.=20 >=20 > --=20 > St=C3=A9phane bingo St=C3=A9phane ! le "sticky bit" positionn=C3=A9 sur /tmp/ emp=C3=AAche l'utilisateur root d= 'alt=C3=A9rer le fichier appartenant au simple utilisateur user ! $ ls -ld /tmp/ drwxrwxrwt 13 root root 320 Dec 17 13:22 /tmp/ $ ls -l /tmp/test=20 -rw-r--r-- 1 user user 0 Dec 17 13:24 /tmp/test $ echo test | sudo tee -a /tmp/test=20 tee: /tmp/test: Permission denied test mais il n'emp=C3=AAche pas sa suppression ! $ sudo rm -v /tmp/test removed '/tmp/test' ce qui m'a induit en erreur : d=C3=A9sol=C3=A9 pour la perte de temps. bonne fin d'ann=C3=A9e 2020, lacsaP.