Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
What's preventing forged ebuilds from a renegade mirror?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
joshtimmons
n00b
n00b


Joined: 20 Jun 2002
Posts: 4

PostPosted: Thu Aug 08, 2002 2:07 am    Post subject: What's preventing forged ebuilds from a renegade mirror? Reply with quote

As far as I know, it's fairly easy to set up a portage mirror. What's to stop some malevolent soul from setting up a mirror, then changing xyz.ebuild to download and install a trojan package instead of the true package?

Hopefully I'm missing something obvious.
Back to top
View user's profile Send private message
delta407
Bodhisattva
Bodhisattva


Joined: 23 Apr 2002
Posts: 2876
Location: Chicago, IL

PostPosted: Thu Aug 08, 2002 2:35 am    Post subject: Re: What's preventing forged ebuilds from a renegade mirror? Reply with quote

joshtimmons wrote:
Hopefully I'm missing something obvious.

Well, obviously, all the Gentoo people are so nice no one would ever think about doing that.

Err...

Maybe the master rsync server should check that the remote servers are actually syncronized. That would fix many other problems as well...
_________________
I don't believe in witty sigs.
Back to top
View user's profile Send private message
joshtimmons
n00b
n00b


Joined: 20 Jun 2002
Posts: 4

PostPosted: Thu Aug 08, 2002 5:50 pm    Post subject: Re: What's preventing forged ebuilds from a renegade mirror? Reply with quote

Thanks for the reply.

I don't think you can rely on the master server to detect that for many reasons - for example, the renegade mirror can always treat the master server as a "special" client and give it the right stuff.

Even if this weren't an attack against the entire user base (which would be very effective, but ultimately non-stealthy, somebody would notice, eventually), this could be used to root individual systems that were known to run Gentoo. This type of attack might never be detected.

I know we're still at the mercy of the upstream packages, but those still generally come from trusted sites and we hope the authors are watching their packages. On the other hand, the portage mirror is unchecked, is a single point of failure for thousands of packages, runs as root, and many people even trust it enough to schedule upgrades.

The only fix is probably signed ebuild files (or the entire portage tree). Without that, it's trivially easy to start owning some boxes.
Back to top
View user's profile Send private message
rac
Bodhisattva
Bodhisattva


Joined: 30 May 2002
Posts: 6553
Location: Japanifornia

PostPosted: Thu Aug 08, 2002 6:27 pm    Post subject: Re: What's preventing forged ebuilds from a renegade mirror? Reply with quote

joshtimmons wrote:
The only fix is probably signed ebuild files (or the entire portage tree).

Signed ebuilds have been a major topic on gentoo-dev recently - This thread is a representative example.
_________________
For every higher wall, there is a taller ladder
Back to top
View user's profile Send private message
sodaphish
n00b
n00b


Joined: 11 Apr 2003
Posts: 3

PostPosted: Fri Apr 11, 2003 3:28 pm    Post subject: This issue needs to be addressed Reply with quote

If Gentoo is going to be taken seriously at the enterprise level, this issue needs to be addressed. Mac OS X had a similar vulnerability in the SoftwareUpdate app (see http://docs.info.apple.com/article.html?artnum=75304 for more information) which was promptly addressed by Apple.

The only thing that would prevent this issue from being a major hurdle to enterprise users is that few people know about it... which, of course, could change.

-C
Back to top
View user's profile Send private message
mmealman
Guru
Guru


Joined: 02 Nov 2002
Posts: 348
Location: Florida

PostPosted: Fri Apr 11, 2003 4:35 pm    Post subject: Reply with quote

Secure Portage is already being worked on.
Back to top
View user's profile Send private message
puddpunk
l33t
l33t


Joined: 20 Jul 2002
Posts: 681
Location: New Zealand

PostPosted: Sat Apr 12, 2003 3:39 am    Post subject: Reply with quote

Currently, the mirror admins of gentoo (the global mirror devs, not the server admins) run scripts frequently to check that all the mirrors are sync'd. if there is a mirror out of sync, that mirror is taken out of round-robin DNS rotation until the mirror is back in sync.

So if content on one mirror differs from the other mirrors, access is cut. It's not foolproof, and it's not an ideal solution. It's what we got.

Ebuild signing, Gentoo uber and dev keys are being thought out at the moment. Have a look through the gentoo-securoty or the gentoo-hardened lists for more information.
Back to top
View user's profile Send private message
Black
Apprentice
Apprentice


Joined: 10 Dec 2002
Posts: 158
Location: Québec, Canada

PostPosted: Sat Apr 12, 2003 4:09 am    Post subject: Reply with quote

A temporary solution might be to download the MD5 from another server. I have no idea how much programming/time would be required for such a thing. "MD5-servers" would have to be limited to a few which would have to be controled.

Then again, maybe it would take as much time to implement as it would for the signed ebuild, making such a solution irrelevant.
Back to top
View user's profile Send private message
sodaphish
n00b
n00b


Joined: 11 Apr 2003
Posts: 3

PostPosted: Mon Apr 14, 2003 9:14 pm    Post subject: ...so Reply with quote

So, in the spirit of keeping the Gentoo Social Contract, does this particular issue have an open Bug ID? If so, what is it?

-C
Back to top
View user's profile Send private message
sodaphish
n00b
n00b


Joined: 11 Apr 2003
Posts: 3

PostPosted: Mon Apr 14, 2003 9:17 pm    Post subject: also of note... Reply with quote

might be that what if an attacker isn't targetting the global Gentoo user-base, but rather a specific installation? The sync reports and DNS round-robin aren't going to save that specific installation -- but a well crafted and secure portage system would.

-C
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum