Assalamualaikum..
=)
hye there!
today i want to share some new information about program Security.
Here, i will tell you some information about viruses, worms, malicious codes and many more.
But, let's start with Secure Program.
Secure Program--------------------------------
Different people have different perspective on software quality.
Usually, developer will track faults during design and code inspection.
Fault?what is fault?
A fault is defined as an abnormal condition or defect at the component, equipment, or sub-system level which may lead to a failure.
Fault - inside view from the developer
Failure?Failure is refers to the state or condition of not meeting a desirable or intended objective, and may be viewed as the opposite of succes
Failure - outside view from developer and are effect of faults.
BugBugs is common term used to describe an error, flaw, mistake, failure, or fault in a computer program or system that produces an incorrect or unexpected result, or causes it to behave in unintended ways.
What is Flaw?We use flaw as a synonym for bug, hence (in IEEE terms) as a synonym for fault, except that we include flaws that have been inserted into a system intentionally, as well as accidental ones.
Types of Flaws:
* Validation Error
* Domain Error
* Serialization and aliasing
* Inadequate identification and authentification
* Boundary condition violation
* Other exploitable logic error.
Non-malicious Program Errors?There are two kind of Nonmalicious Program Errors:
* Buffer overflow
* Incomplete mediation which refer to data exposed or uncontrolled.
There are some attack associated to program error:
* Cross site scripting
* injection Flaws
* Malicious File execution
* Broken authentication and session management
* insecure crypto storage.
Now let's move to a topic called Virus and Other Malicious Code.
Malicious Codes--------------------------------
Malicious codes can do harm and can also be accidental.
Malicious codes is unanticipated or undesired effects in programs generated on the intent of damage.
Damage could be in form of:
* modification
* stolen data
* unauthorized access
* Damage on system
Example of Malicious Codes:
* Trojan Horse - a program which performs a useful and unexpected function as well.
* Virus - code segment which replicates by attaching copies to existing executable.
* Worm - a program which replicates until it fills all disk space or CPU cycles.
* Logic Bombs - malicious code that activates on an event.
* Trap door or Back door - undocumented entry point that allow unwanted user.
* spyware - can steal your information which done by keystroke logger and even though you use encryption on connection the damage is already done before you can send it. It also can steal your email addresses, can see what Websites you visit, can pop ups ads, slow down computer and crash our computer.
Viruses and Malicious Program-----------------------------------------------
Computer viruses have the ability to replicate themselves on an ever increasing number of computers. They original spread by people sharing floppy disc. Now they are spread primarily over the Internet.
Malicious Program may be installed by hand on a single machine. They may also be built into widely distributed commercial software package. They are hard to detect before the payload activates.
Malicious program is divided to two part which is 'Need Host Program' and 'Independent'.
Need Host Program contains trapdoors, Logic Bombs,Trojan Horses and Viruses
Independent contains Bacteria and Worms (same species)
Okay, Let's talk about Viruses------------------------------------------------
Personal computer viruses exploit the lack of effective access control in these systems.
Viruses are divided to two:
*
transient which only executes when the program that it is attached to runs.
*
Resident which once the program executes the virus stays in memory until it gets triggered again. Terminates and stay Resident (TSR).
There are some characteristics of virus:
*
replication* required a
host program* activated by
external actions.
* replication is
limited to virtual system.
* designed to attack single platform.
How Virus Attach?------------------------------------
There are three ways for virus to attach:
1)
Append Viruses which is execue first then transfer control tooriginal program.
2)
Surround Viruses which has control before and after regular program.
3)
Integrated Viruses which replace some of the target program or all of the target and give the effect that the target program worked.
A = original program
B = Virus B
A + B = AB or BA;How Virus Gain Control-----------------------------------------
The virus needs to have the CPU execute it to be in control. One way for them is to
overwrite the program on the disk.
Another way is
to move the original program and then after the CPU executes it then and then after the CPU executes it then
transfer control to the program.Another way is
to install itself in memory and change the pointers of the operating system or interrupt table to point to it.
Home for Viruses----------------------------------
* Viruses install itself in the boot sector (MBR)
master boot record.
*
Memory Resident Virus (TSR) which is to terminate and stay resident.
* Application like
word processor and spread sheets and even attachment to email.
* Even attachments to vendor
distributed programs or games.
The Source of Viruses---------------------------------------
Virus program can be small so it hides very easily in a large program. It might hide in a compiler, a database manager or file manager.
The number one spot is an attachment to email or some public download file.
Virus Phase----------------------
*
Dormant phase : the virus is idle
*
Propagation phase : the virus places an identical copy of itself into other programs.
*
Triggering Phase : the virus is activated to perform the function for which it was intended.
*
Execution Phase: The function is performed.
There are five types of viruses:--------------------------------------------
*
Parasitic Virus: attaches itself to executable files as part of their code. Runs whenever the host program runs.
*
Memory- Resident Virus: Lodges in main memory as part of the residual operating system.
*
Boot Sector Virus: infexcts the boot sector of a disc and spreads when the operating system boots up.
*
Stealth Virus: explicitly designed to hide from Virus Scanning programs.
*
Polymorphic Virus: mutates with every new host to prevent signature detection.
Virus is so dangerous for our computer and files. So,
How to prevent Virus Infection?* Protection against Viruses which we need
detection tools such as scanner and vulnerability monitors, then we need
identification tools and
removal tools such as disinfector.
* Scanner and disinfectors are the most popular classes of antivirus software.
* Personal and administrative practise
* Make a bootable disk with a virus scan program on it and write protected.
* Make and retain backup copies of executable system files.
* scan any downloaded files before runs.
* Updates the virus signatures data files.
* Use only commercial software.
* Do not open attachment without any scanning.
* do not put floppy disc in machines.
Now let's talk about
Worm.
-------------------------------------
Worm have some characteristics:
* self-contained which do not required host.
* replication
* activated by creating process.
* replication occurs across communication link (network worm).
How Worm attack?A = original prograam
B = Worm
A + B = A+B+B;
How to protect files from Worm..?-----------------------------------------------------
* requires a combination of basic system security and good network security.
* add- on tools which have configuration review tools, checksum and intrusion detection tools.
* network security tools which contains wrapper program and firewall system.
Trapdoors------------------------------
is often caused by programmers leaving debug routines in the code or failure to check array bounds which lets code overrun the array bounds and get placed on the stack.
Maybe programmer forgets to remove them or intentionally leaves them in for testing.
Maybe programmer also leave it intentionally for maintenance of the finished products.
Pillar of Software Security--------------------------------------
* Risk Management - Help user to understand what they should do abaout risk and build better software.
* Touchpoint

* Knowledge which includes principles, guidelines, rules, attack patterns, vulnerabilities and Historical risks.
Okay, i pen off now..