mirror of
				https://github.com/sqlmapproject/sqlmap.git
				synced 2025-10-26 05:31:04 +03:00 
			
		
		
		
	minor improvements
This commit is contained in:
		
							parent
							
								
									4c13e0e5a1
								
							
						
					
					
						commit
						df3cc38cd9
					
				|  | @ -169,14 +169,16 @@ def liveTest(): | |||
|         msg = "running live test case: %s (%d/%d)" % (name, count, length) | ||||
|         logger.info(msg) | ||||
| 
 | ||||
|         try: | ||||
|             result = runCase(switches, parse) | ||||
|         except SqlmapNotVulnerableException: | ||||
|             vulnerable = False | ||||
|         initCase(switches) | ||||
| 
 | ||||
|         test_case_fd = codecs.open(os.path.join(paths.SQLMAP_OUTPUT_PATH, "test_case"), "wb", UNICODE_ENCODING) | ||||
|         test_case_fd.write("%s\n" % name) | ||||
| 
 | ||||
|         try: | ||||
|             result = runCase(parse) | ||||
|         except SqlmapNotVulnerableException: | ||||
|             vulnerable = False | ||||
| 
 | ||||
|         if result is True: | ||||
|             logger.info("test passed") | ||||
|             cleanCase() | ||||
|  | @ -250,13 +252,11 @@ def initCase(switches=None): | |||
| def cleanCase(): | ||||
|     shutil.rmtree(paths.SQLMAP_OUTPUT_PATH, True) | ||||
| 
 | ||||
| def runCase(switches=None, parse=None): | ||||
| def runCase(parse): | ||||
|     global failedItem | ||||
|     global failedParseOn | ||||
|     global failedTraceBack | ||||
| 
 | ||||
|     initCase(switches) | ||||
| 
 | ||||
|     LOGGER_HANDLER.stream = sys.stdout = tempfile.SpooledTemporaryFile(max_size=0, mode="w+b", prefix="sqlmapstdout-") | ||||
|     retVal = True | ||||
|     handled_exception = None | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user