Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 15819 Details for
Bug 26280
antivirus hooks for portage
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch that adds the hooks to ebuild to do antivirus scanning
ebuild.sh-1.137.diff (text/plain), 1.54 KB, created by
solar (RETIRED)
on 2003-08-09 10:07:14 UTC
(
hide
)
Description:
Patch that adds the hooks to ebuild to do antivirus scanning
Filename:
MIME Type:
Creator:
solar (RETIRED)
Created:
2003-08-09 10:07:14 UTC
Size:
1.54 KB
patch
obsolete
>Index: ebuild.sh >=================================================================== >RCS file: /home/cvsroot/gentoo-src/portage/bin/ebuild.sh,v >retrieving revision 1.137 >diff -u -b -B -r1.137 ebuild.sh >--- ebuild.sh 30 Jul 2003 13:28:24 -0000 1.137 >+++ ebuild.sh 9 Aug 2003 16:34:47 -0000 >@@ -252,11 +252,39 @@ > } > > >+# the antivirus feature should be disabled by default except when >+# overridden in the relevant stages >+ >+antivirus_scan() { >+ local buf >+ local ret >+ local x >+ >+ x=$1 >+ ret=1 >+ >+ ebegin ">>> Virus Scanning ${x} " >+ if [ -x "${AVS_SCANNER}" ]; then >+ # this assumes the syntax of "execfile options file/dir" >+ buf=$(${AVS_SCANNER} ${AVS_OPTS} ${x}) >+ ret=$? >+ [ ${ret} != 0 ] && myfail="something here " >+ else >+ myfail="No usable AVS_SCANNER found: ${AVS_SCANNER}" >+ fi >+ eend $ret >+ if [ "${myfail}" != "" ] ; then >+ echo "${buf}" >+ die "${myfail}" >+ fi >+} >+ > unpack() { > local x > local y > local myfail > local tarvars >+ local vscan > > if [ "$USERLAND" == "BSD" ]; then > tarvars="" >@@ -264,7 +292,12 @@ > tarvars="--no-same-owner" > fi > >+ vscan=`has antivirus $FEATURES` >+ > for x in "$@"; do >+ if [ "${vscan}" != "" ]; then >+ antivirus_scan $(pwd)/${x} >+ fi > myfail="failure unpacking ${x}" > echo ">>> Unpacking ${x} to $(pwd)" > y="$(echo $x | sed 's:.*\.\(tar\)\.[a-zA-Z0-9]*:\1:')" >@@ -761,6 +794,10 @@ > prepall > cd ${D} > >+ if [ "`has antivirus $FEATURES`" != "" ]; then >+ # scan the whole directory >+ antivirus_scan ${D}/ >+ fi > declare -i UNSAFE=0 > for i in $(find ${D}/ -type f -perm -2002); do > UNSAFE=$(($UNSAFE + 1))
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 26280
: 15819