Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 179008 - portage- has wrong permissions for it's cache wrt to repoman and metadata.dtd
Summary: portage- has wrong permissions for it's cache wrt to repoman and meta...
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Unclassified (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Portage team
Keywords: InVCS
Depends on:
Blocks: 181949
  Show dependency tree
Reported: 2007-05-18 14:41 UTC by Gustavo Zacarias (RETIRED)
Modified: 2007-05-31 01:28 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Note You need to log in before you can comment on or make changes to this bug.
Description Gustavo Zacarias (RETIRED) gentoo-dev 2007-05-18 14:41:09 UTC
When a new release is built at the stage1 phase /var/cache/edb is created with perms 755.
Repoman uses metadata.dtd in the cache directory for commits, it fetches it into distfiles and moves it into the cache dir and it fails there since the dir isn't group writable (portage) with this being done as a simple and mortal user.
Thus 2007.0 stages aren't good out of the box for devs.
Comment 1 Marius Mauch (RETIRED) gentoo-dev 2007-05-18 17:14:23 UTC
As I mentioned on IRC, from a quick scan the relevant code in portage hasn't changed in the last 12 months, so don't know why it worked before (it sets the permissions to 755).
Comment 2 Zac Medico gentoo-dev 2007-05-18 18:54:55 UTC
The 0755 that's in config._init_dirs() will allow earlier permissions to bleed through if they're not explicitly masked.  So, the user can `chmod g +w /var/cache/edb` and the bit will not be removed by portage.  Looking at from portage-2.0.54, it used to set 0775 permissions on CACHE_PATH, so that's one place the bit would have been set automatically in the past that it isn't now.

Perhaps repoman should simply use the metadata.dtd directly from $DISTDIR.  Copying it to /var/cache/edb doesn't really make a difference since it doesn't lock the file while it's using it anyway.
Comment 3 Zac Medico gentoo-dev 2007-05-20 22:54:15 UTC
In svn r6562 I've fixed it to use metadata.dtd directly from $DISTDIR.
Comment 4 Zac Medico gentoo-dev 2007-05-25 09:08:55 UTC
This has been released in
Comment 5 Jakub Moc (RETIRED) gentoo-dev 2007-05-25 23:03:43 UTC
I/O error : Attempt to load network entity 

whenever I run repoman; gets repeated for every ebuild it checks.
Comment 6 Zac Medico gentoo-dev 2007-05-26 20:40:13 UTC
(In reply to comment #5)
> I/O error : Attempt to load network entity

Sorry about that.  I had the following entry in /etc/xml/catalog which prevented me from receiving that message:

<rewriteURI uriStartString="" rewritePrefix="/usr/portage/metadata/dtd/"/>

It's fixed in svn r6632 so that message is hidden like before unless there's a real error from xmllint.
Comment 7 Zac Medico gentoo-dev 2007-05-31 01:28:54 UTC
This has been released in