Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Professor Offenberg teaches an excellent Ethical Hacking class here at HCC . Unfortunately, his evil twin brother, Darth Offenberg, is the head of the international
Professor Offenberg teaches an excellent Ethical Hacking class here at HCC Unfortunately, his
evil twin brother, Darth Offenberg, is the head of the international crime group Offenbergs
Unethical Computer Hackers OUCH Hackers from OUCH are trying to penetrate your system.
OUCH always begin with one of three IP address ranges in the first two octets:
You have been forwarded a file called ipfiletxt This file contains an unknown number of IP
addresses and the data and time that the IP address accessed your system. Your job is to read
the file, find all the suspect IP addresses that might have been used by OUCH, and produce an
output report to both the screen and to an output file.
The program must allow the user to enter in the name of the input file:
a The program must call a function that receives the input filename as a parameter
b The program must use a try..except block to test that the file exists; if it does not
exist, the program must display the appropriate error message and allow the
reentry of the filename
c Once the program determines that the file exists, the function must return the file
handle
The program must allow the user to enter in the name of the output file:
a The program must call the same function as above that receives the output
filename as a parameter
b The program must use a try..except block to test that the file can be crated; if it
cannot be created, the program must display the appropriate error message and
allow the reentry of the filename
c Once the program determines that the file can be created, the function must
return the file handle
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started