rtruxal / metagoofil

Automatically exported from code.google.com/p/metagoofil
GNU General Public License v2.0
0 stars 0 forks source link

Global variables not propagating to subroutines #1

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Download megagoofil-readonly from svn
2. Run the code without defining values for "-l" or "-n"

What is the expected output? What do you see instead?
The expected output is for the default values to be used as defined in 
metagoofil.py:
limit=100
filelimit=50

What version of the product are you using? On what operating system?
svn release metagoofil-read-only dated May 16, 2011 (revision 2)

Please provide any additional information below.

The shell output below shows what happens when these values are not provided on 
the command line (the code exits in line 126 of metagoofil.py upon attempting 
to convert filelimit into a string)

[** This shows a fresh svn checkout, followed by an attempt to run metagoofil 
without filelimit and without limit specified on the command line.  Result: 
Failure to download **]
Checked out revision 2.
gray@fireball:~/metagoofil$ cd metagoofil-read-only/
gray@fireball:~/metagoofil/metagoofil-read-only$ python ./metagoofil.py -d 
iastate.edu -f iastate-download.html -o iastate -t doc

*************************************
* Metagoofil Ver 2.0 - Reborn       *
* Christian Martorella              *
* Edge-Security.com                 *
* cmartorella_at_edge-security.com  *
* BACKTRACK 5 Edition!!             *
*************************************
['doc']
[-] Starting online search...
[** Program dies at this point -PG **]

[** This shows a fresh svn checkout, followed by an attempt to run metagoofil 
without filelimit specified on the command line.  Result: Failure to download 
**]

gray@fireball:~/metagoofil/metagoofil-read-only$ python ./metagoofil.py -d 
iastate.edu -f iastate-download.html -o iastate -t doc -l 10

[** This shows a fresh svn checkout, followed by an attempt to run metagoofil 
with filelimit and with limit specified on the command line.  Result: Success 
**]
gray@fireball:~/metagoofil/metagoofil-read-only$ python ./metagoofil.py -d 
iastate.edu -f iastate-download.html -o iastate -t doc -l 10 -n 10

*************************************
* Metagoofil Ver 2.0 - Reborn       *
* Christian Martorella              *
* Edge-Security.com                 *
* cmartorella_at_edge-security.com  *
* BACKTRACK 5 Edition!!             *
*************************************
['doc']
[-] Starting online search...

[-] Searching for doc files, with a limit of 10
        Searching 100 results...
Results: 105 files found
Starting to download 10 of them..
----------------------------------------------------

[0/10] http://www.registrar.iastate.edu/calendar/Deptcal1011.doc
[1/10] http://www.mcdb.iastate.edu/MCDBhandbook20102011.doc
[2/10] http://www.registrar.iastate.edu/courses/changesupdates2011.doc
[3/10] http://www.registrar.iastate.edu/courses/changesupdatef2011.doc
[4/10] http://www.philrs.iastate.edu/Rottlerapp.doc
[5/10] http://www.immunobiology.iastate.edu/IMBIOHandbook20102011.doc
[6/10] http://www.stuorg.iastate.edu/isss/SEDSGuidelines.doc
[7/10] http://www.registrar.iastate.edu/veterans/vabenefits.doc
[8/10] http://lasonline.iastate.edu/pdf_files/Online_CDG.doc
[9/10] http://www.bus.iastate.edu/jmcelroy/McElroy.doc
[10/10] http://www.hrs.iastate.edu/ISUOnLine/VeteransPref.doc

[+] List of users found:
--------------------
 mkmcdow
 cchulse
 Kathryn B.  Andre
 Katie
 adptemp
 bjhotch
 Janet Krengel
 Aragorn
 AerE Department
 Iowa State University
 Molly Helmers
 College of Business
 McElroy, James C
 marleneb
 cball

[+] List of software found:
-----------------------
 Microsoft Office Word
 Microsoft Word 10.0
 Microsoft Macintosh Word

[+] List of paths and servers found:
--------------------------------
 Normal.dotm
 Normal
 Normal.dot

Attached patch addresses the issue.

Original issue reported on code.google.com by lnxp...@gmail.com on 16 Jun 2011 at 2:46

Attachments: