Page MenuHomeFreeBSD

portsnap: use lam on the 'good' hash list instead of sed on the untrusted one
ClosedPublic

Authored by emaste on Sep 29 2016, 1:43 PM.
Tags
None
Referenced Files
F115155773: D8074.id.diff
Mon, Apr 21, 12:06 AM
Unknown Object (File)
Sat, Apr 19, 2:41 AM
Unknown Object (File)
Fri, Apr 18, 8:04 PM
Unknown Object (File)
Fri, Apr 18, 4:50 PM
Unknown Object (File)
Mon, Apr 14, 6:15 AM
Unknown Object (File)
Mon, Apr 14, 3:15 AM
Unknown Object (File)
Mon, Apr 14, 2:26 AM
Unknown Object (File)
Mar 7 2025, 4:47 AM
Subscribers

Details

Summary

This change should be equivalent to the approach committed in rS306417, but if sed has a bug it could be exploited by the untrusted tar file. Instead, convert the expected hash list to the expected tar content filesystem layout, and compare that with find's output.

Submitted by: @cperciva in D8052

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

emaste retitled this revision from to portsnap: use lam on the 'good' hash list instead of sed on the untrusted one.
emaste updated this object.
emaste edited the test plan for this revision. (Show Details)
emaste added reviewers: cperciva, allanjude.
emaste added a subscriber: cperciva.

I am capsicumizing lam(1), and will have a review soon

oshogbo edited edge metadata.
oshogbo added inline comments.
usr.sbin/portsnap/portsnap/portsnap.sh
694

\ - is not needed, or you should add some space like in rest file.

This revision is now accepted and ready to land.Oct 7 2016, 7:52 PM