GNU bug report logs - #68810
29.1; Recommending setting transfer.fsckObjects of git to true is not necessary

Previous Next

Package: emacs;

Reported by: Lin Jian <me <at> linj.tech>

Date: Mon, 29 Jan 2024 23:30:02 UTC

Severity: wishlist

Found in version 29.1

To reply to this bug, email your comments to 68810 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#68810; Package emacs. (Mon, 29 Jan 2024 23:30:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Lin Jian <me <at> linj.tech>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Mon, 29 Jan 2024 23:30:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Lin Jian <me <at> linj.tech>
To: bug-gnu-emacs <at> gnu.org
Subject: 29.1; Recommending setting transfer.fsckObjects of git to true is
 not necessary
Date: Tue, 30 Jan 2024 07:16:45 +0800
Recommendation about setting transfer.fsckObjects of git to true can be
found in admin/notes/git-workflow and CONTRIBUTE.  In addition, it is
set in autogen.sh.

This is triggered by a discussion[1] on emacs-devel.  The first commit
about this is cedd7cad092809a97c1ed7fb883b68fa844cea58 on 2016-01-31.
However, on 2016-02-04, another discussion[2] shows that git is secure
by default so setting this option is not necessary.

What about removing this unnecessary recommendation?

By the way, the same recommendation can be found on Emacswiki[3][4].

[1]: https://lists.gnu.org/r/emacs-devel/2016-01/msg01802.html
[2]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=813157#29
[3]: https://www.emacswiki.org/emacs/GitQuickStartForEmacsDevs
[4]: https://www.emacswiki.org/emacs/GitForEmacsDevs






Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#68810; Package emacs. (Tue, 30 Jan 2024 00:41:02 GMT) Full text and rfc822 format available.

Message #8 received at 68810 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefankangas <at> gmail.com>
To: Lin Jian <me <at> linj.tech>, 68810 <at> debbugs.gnu.org
Subject: Re: bug#68810: 29.1; Recommending setting transfer.fsckObjects of git
 to true is not necessary
Date: Mon, 29 Jan 2024 19:39:54 -0500
Lin Jian via "Bug reports for GNU Emacs, the Swiss army knife of text
editors" <bug-gnu-emacs <at> gnu.org> writes:

> Recommendation about setting transfer.fsckObjects of git to true can be
> found in admin/notes/git-workflow and CONTRIBUTE.  In addition, it is
> set in autogen.sh.
>
> This is triggered by a discussion[1] on emacs-devel.  The first commit
> about this is cedd7cad092809a97c1ed7fb883b68fa844cea58 on 2016-01-31.
> However, on 2016-02-04, another discussion[2] shows that git is secure
> by default so setting this option is not necessary.
>
> What about removing this unnecessary recommendation?
>
> By the way, the same recommendation can be found on Emacswiki[3][4].
>
> [1]: https://lists.gnu.org/r/emacs-devel/2016-01/msg01802.html
> [2]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=813157#29
> [3]: https://www.emacswiki.org/emacs/GitQuickStartForEmacsDevs
> [4]: https://www.emacswiki.org/emacs/GitForEmacsDevs

Are you sure?  The git documentation says:

    transfer.fsckObjects

    When fetch.fsckObjects or receive.fsckObjects are not set, the value
    of this variable is used instead. Defaults to false.

    When set, the fetch or receive will abort in the case of a malformed
    object or a link to a nonexistent object. In addition, various other
    issues are checked for, including legacy issues (see fsck.<msg-id>),
    and potential security issues like the existence of a .GIT directory
    or a malicious .gitmodules file (see the release notes for v2.2.1
    and v2.17.1 for details). Other sanity and security checks may be
    added in future releases.

https://git-scm.com/docs/git-config#Documentation/git-config.txt-transferfsckObjects




Severity set to 'wishlist' from 'normal' Request was from Stefan Kangas <stefankangas <at> gmail.com> to control <at> debbugs.gnu.org. (Tue, 30 Jan 2024 00:42:01 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#68810; Package emacs. (Tue, 30 Jan 2024 12:15:01 GMT) Full text and rfc822 format available.

Message #13 received at 68810 <at> debbugs.gnu.org (full text, mbox):

From: Lin Jian <me <at> linj.tech>
To: Stefan Kangas <stefankangas <at> gmail.com>
Cc: 68810 <at> debbugs.gnu.org
Subject: Re: bug#68810: 29.1; Recommending setting transfer.fsckObjects of
 git to true is not necessary
Date: Tue, 30 Jan 2024 19:57:16 +0800
Stefan Kangas <stefankangas <at> gmail.com> writes:

> Are you sure?

I am no expert of git.  So I am not sure.

That being said, have you read those links in my report?  My point is
that the motivation of setting transfer.fsckObjects in [1], i.e.,
security, is made invalid in [2] because git is secure by default.
However, related commits are made before (and after) [2].

[1]: https://lists.gnu.org/r/emacs-devel/2016-01/msg01802.html
[2]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=813157#29




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#68810; Package emacs. (Tue, 30 Jan 2024 12:28:01 GMT) Full text and rfc822 format available.

Message #16 received at 68810 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Stefan Kangas <stefankangas <at> gmail.com>
Cc: me <at> linj.tech, 68810 <at> debbugs.gnu.org
Subject: Re: bug#68810: 29.1;
 Recommending setting transfer.fsckObjects of git to true is not
 necessary
Date: Tue, 30 Jan 2024 14:27:07 +0200
> From: Stefan Kangas <stefankangas <at> gmail.com>
> Date: Mon, 29 Jan 2024 19:39:54 -0500
> 
> Lin Jian via "Bug reports for GNU Emacs, the Swiss army knife of text
> editors" <bug-gnu-emacs <at> gnu.org> writes:
> 
> > Recommendation about setting transfer.fsckObjects of git to true can be
> > found in admin/notes/git-workflow and CONTRIBUTE.  In addition, it is
> > set in autogen.sh.
> >
> > This is triggered by a discussion[1] on emacs-devel.  The first commit
> > about this is cedd7cad092809a97c1ed7fb883b68fa844cea58 on 2016-01-31.
> > However, on 2016-02-04, another discussion[2] shows that git is secure
> > by default so setting this option is not necessary.
> >
> > What about removing this unnecessary recommendation?
> >
> > By the way, the same recommendation can be found on Emacswiki[3][4].
> >
> > [1]: https://lists.gnu.org/r/emacs-devel/2016-01/msg01802.html
> > [2]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=813157#29
> > [3]: https://www.emacswiki.org/emacs/GitQuickStartForEmacsDevs
> > [4]: https://www.emacswiki.org/emacs/GitForEmacsDevs
> 
> Are you sure?  The git documentation says:
> 
>     transfer.fsckObjects
> 
>     When fetch.fsckObjects or receive.fsckObjects are not set, the value
>     of this variable is used instead. Defaults to false.
> 
>     When set, the fetch or receive will abort in the case of a malformed
>     object or a link to a nonexistent object. In addition, various other
>     issues are checked for, including legacy issues (see fsck.<msg-id>),
>     and potential security issues like the existence of a .GIT directory
>     or a malicious .gitmodules file (see the release notes for v2.2.1
>     and v2.17.1 for details). Other sanity and security checks may be
>     added in future releases.
> 
> https://git-scm.com/docs/git-config#Documentation/git-config.txt-transferfsckObjects

And I have another question: does this setting cause any harm, or can
cause any harm in some situations?  IOW, what are the downsides of
using this setting?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#68810; Package emacs. (Tue, 30 Jan 2024 13:19:02 GMT) Full text and rfc822 format available.

Message #19 received at 68810 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Lin Jian <me <at> linj.tech>
Cc: stefankangas <at> gmail.com, 68810 <at> debbugs.gnu.org
Subject: Re: bug#68810: 29.1;
 Recommending setting transfer.fsckObjects of git to true is not
 necessary
Date: Tue, 30 Jan 2024 15:18:18 +0200
> Cc: 68810 <at> debbugs.gnu.org
> Date: Tue, 30 Jan 2024 19:57:16 +0800
> From:  Lin Jian via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
> 
> 
> Stefan Kangas <stefankangas <at> gmail.com> writes:
> 
> > Are you sure?
> 
> I am no expert of git.  So I am not sure.
> 
> That being said, have you read those links in my report?  My point is
> that the motivation of setting transfer.fsckObjects in [1], i.e.,
> security, is made invalid in [2] because git is secure by default.

AFAIR, we added that setting because of real problems, not because of
some theoretical concerns.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#68810; Package emacs. (Tue, 30 Jan 2024 13:53:01 GMT) Full text and rfc822 format available.

Message #22 received at 68810 <at> debbugs.gnu.org (full text, mbox):

From: Lin Jian <me <at> linj.tech>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: Stefan Kangas <stefankangas <at> gmail.com>, 68810 <at> debbugs.gnu.org
Subject: Re: bug#68810: 29.1; Recommending setting transfer.fsckObjects of
 git to true is not necessary
Date: Tue, 30 Jan 2024 21:48:45 +0800
Eli Zaretskii <eliz <at> gnu.org> writes:

> And I have another question: does this setting cause any harm, or can
> cause any harm in some situations?  IOW, what are the downsides of
> using this setting?

I am not aware of any downsides of using this setting.

My motivation is to remind Emacs developers that this setting is not
necessary.  How you deal with this unnecessary setting is up to you.  I
personally prefer upstream (git) default though.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#68810; Package emacs. (Tue, 30 Jan 2024 14:00:02 GMT) Full text and rfc822 format available.

Message #25 received at 68810 <at> debbugs.gnu.org (full text, mbox):

From: Lin Jian <me <at> linj.tech>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: stefankangas <at> gmail.com, 68810 <at> debbugs.gnu.org
Subject: Re: bug#68810: 29.1; Recommending setting transfer.fsckObjects of
 git to true is not necessary
Date: Tue, 30 Jan 2024 21:53:02 +0800
Eli Zaretskii <eliz <at> gnu.org> writes:

> AFAIR, we added that setting because of real problems, not because of
> some theoretical concerns.

Both related content in git-workflow and commit messages of related
commits[1][2][3][4] point the motivation to only [5].

If there are indeed real problems I am not aware of, then my report is
not valid and I am sorry for the noise.

[1]: cedd7cad092809a97c1ed7fb883b68fa844cea58
[2]: d766ca8ff1e4ff1a30385508e1f456fad6bfe9f8
[3]: ee8b46699523cc1dea7b3d03e3cccff3d62cd847
[4]: f8bf1b35bf55ae1bb7703f86d3b526887f064b19
[5]: https://lists.gnu.org/r/emacs-devel/2016-01/msg01802.html




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#68810; Package emacs. (Tue, 30 Jan 2024 14:24:01 GMT) Full text and rfc822 format available.

Message #28 received at 68810 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Lin Jian <me <at> linj.tech>
Cc: stefankangas <at> gmail.com, 68810 <at> debbugs.gnu.org
Subject: Re: bug#68810: 29.1; Recommending setting transfer.fsckObjects of
 git to true is not necessary
Date: Tue, 30 Jan 2024 16:22:43 +0200
> From: Lin Jian <me <at> linj.tech>
> Cc: stefankangas <at> gmail.com, 68810 <at> debbugs.gnu.org
> Date: Tue, 30 Jan 2024 21:53:02 +0800
> 
> 
> Eli Zaretskii <eliz <at> gnu.org> writes:
> 
> > AFAIR, we added that setting because of real problems, not because of
> > some theoretical concerns.
> 
> Both related content in git-workflow and commit messages of related
> commits[1][2][3][4] point the motivation to only [5].

AFAIR, there were problems with fetching from elpa.git at some point,
which would have been avoided if fsckObjects were used.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#68810; Package emacs. (Tue, 30 Jan 2024 20:50:01 GMT) Full text and rfc822 format available.

Message #31 received at 68810 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefankangas <at> gmail.com>
To: Lin Jian <me <at> linj.tech>
Cc: 68810 <at> debbugs.gnu.org
Subject: Re: bug#68810: 29.1; Recommending setting transfer.fsckObjects of git
 to true is not necessary
Date: Tue, 30 Jan 2024 15:49:34 -0500
Lin Jian <me <at> linj.tech> writes:

> Stefan Kangas <stefankangas <at> gmail.com> writes:
>
>> Are you sure?
>
> I am no expert of git.  So I am not sure.
>
> That being said, have you read those links in my report?  My point is
> that the motivation of setting transfer.fsckObjects in [1], i.e.,
> security, is made invalid in [2] because git is secure by default.
> However, related commits are made before (and after) [2].

Yes, I read the links.  But I tend to trust the official documentation
more than some random opinions shared online, and the part I quoted says
that this setting _does_ enable some checks that would otherwise not be
done.




This bug report was last modified 1 year and 136 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.