unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: Jean Louis <bugs@gnu.support>
Cc: 57044@debbugs.gnu.org
Subject: bug#57044: 29.0.50; tramp-error: Reading directory: Permission denied, /scp:motorolausb:/storage/emulated/0/
Date: Tue, 06 Sep 2022 13:18:32 +0200	[thread overview]
Message-ID: <87h71kagzb.fsf@gmx.de> (raw)
In-Reply-To: <YxLPDz7Wl+E5HPiU@protected.localdomain> (Jean Louis's message of "Sat, 3 Sep 2022 06:50:39 +0300")

Jean Louis <bugs@gnu.support> writes:

Hi Jean,

> Now I could enter directory listing, I can open file in the root
> directory,

How did you solve the issue?

> These are directories:
>
>   drwxrwx---  2 root everybody  4096 Jun 16  1971 Alarms
>   drwxrwx---  4 root everybody  4096 Jun 16  1971 Android
>   drwxrwx---  6 root everybody  4096 May 21 08:26 Androzic
>
> I cannot enter into directories.

"everybody" is not your primary user group.

Tramp has been optimized to increase the speed recently. It does not
send the "test -r <file>" command anymore. Instead, it checks the
permissions of the file, which it knows already.

However, it has checked permissions for your primary group only. That's
not sufficient, so I've changed Tramp to respect the secondary groups as
well. Could you, please, check with recent git master whether it works
for you?

> Let us say file is this one:
>
>   -rw-rw----  1 root everybody    55 Sep  1 17:18 police-jinja.txt
>
> Then I can enter into file but cannot edit it, it is read only by
> Tramp. But if I use same ssh connection and enter into ssh from shell,
> I can edit the file, which means it is not really read only, just that
> Tramp thinks so.

That's another case, it is about a file being writable, and not only
readable. This is not a regression in Tramp (the same happens in Emacs
28). And I've tried your scenario out of Emacs. I have a file
/tmp/wheel, with the following permissions:

--8<---------------cut here---------------start------------->8---
# ll /tmp/wheel
-rwxr-x---  1 root  wheel  4 Sep  5 16:04 /tmp/wheel*
--8<---------------cut here---------------end--------------->8---

I have added myself to group wheel:

--8<---------------cut here---------------start------------->8---
# grep wheel /etc/group
wheel:*:0:root,albinus
--8<---------------cut here---------------end--------------->8---

However, I cannot change this file:

--8<---------------cut here---------------start------------->8---
# cat 123 >>/tmp/wheel
/tmp/wheel: Permission denied.
--8<---------------cut here---------------end--------------->8---

So this is the expected bahavior.

> NOTE: Tramp was working well, and I did not change my devices neither
> settings, I can only think that something was changed inside of Tramp.

Yes. As said, Tramp is permanently being optimized, mainly for
performance improvements. I try to avoid regressions, but it could
happen.

Best regards, Michael.





  reply	other threads:[~2022-09-06 11:18 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-07 19:25 bug#57044: 29.0.50; tramp-error: Reading directory: Permission denied, /scp:motorolausb:/storage/emulated/0/ Jean Louis
2022-08-08  8:57 ` Michael Albinus
2022-08-11 21:33   ` Jean Louis
2022-08-12 11:07     ` Michael Albinus
2022-08-13  5:20       ` Jean Louis
2022-08-13  9:44         ` Michael Albinus
2022-08-14  4:12           ` Jean Louis
2022-08-14 15:03             ` Michael Albinus
2022-08-15 12:13               ` Michael Albinus
2022-08-15 17:39                 ` Michael Albinus
2022-08-16  4:43                 ` Jean Louis
2022-08-16  6:06                   ` Michael Albinus
2022-08-16  8:50                     ` Jean Louis
2022-08-16  8:46                 ` Jean Louis
2022-08-16  8:55               ` Jean Louis
2022-08-16 13:19                 ` Michael Albinus
2022-08-17 13:47           ` Jean Louis
2022-08-14  4:08       ` Jean Louis
2022-08-17 15:51   ` Jean Louis
2022-08-25 18:59     ` Michael Albinus
2022-09-03  3:50       ` Jean Louis
2022-09-06 11:18         ` Michael Albinus [this message]
2022-09-15 15:24           ` Michael Albinus
2022-09-15 19:08             ` Jean Louis
2022-09-16  9:05               ` Michael Albinus
2022-09-16 11:14                 ` Jean Louis
2022-09-15 21:42             ` Jean Louis
2022-09-16 11:44               ` Michael Albinus
2022-09-17  2:12                 ` Jean Louis
2022-09-17  6:35                   ` Michael Albinus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87h71kagzb.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=57044@debbugs.gnu.org \
    --cc=bugs@gnu.support \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).