module seven
DESCRIPTION
Module Seven. Computer Software. Computer Software Computer Software. How applications work. Computer Software Computer Software. A sequence of instructions to do a task is called a program . Also known as software, or sometimes a script. Computer Software Computer Software. - PowerPoint PPT PresentationTRANSCRIPT
Module Seven
Computer Software
Computer Software
Computer Software• How applications work.
Computer Software
Computer Software• A sequence of instructions to do a task
is called a program.– Also known as software, or sometimes a
script.
Computer Software
Computer Software• Some Examples -
Computer Software
Computer Software• Word
Computer Software
Computer Software• Excel
Computer Software
Computer Software• Outlook
Computer Software
Computer Software• Internet
Explorer
Computer Software
Computer Software• Internet
Explorer6
Computer Software
Computer Software• Firefox
Computer Software
Computer Software• Safari
Computer Software
Computer Software• Adobe
Acrobat
Computer Software
Computer Software• Skype
Computer Software
Computer Software• World
ofWarcraft
Computer Software
Computer Software• All of these use
– the execution of instructions, and– The manipulation of data
that we saw in the last section.
Computer Software
Computer Software• Now, we’ll examine the concept of
computer programs in a little more detail.
Machine Language
Computer Software Binary Codes
• Inside the computer,every piece of information is either a 0 or a 1.
• These can be represented electrically or magnetically.
Computer Software Binary Codes
• A single 0/1 value is a bit.• Every byte in memory is a group of eight bits.
– Remember, that a computer’s memory is measured as megabytes or gigabytes.
Computer Software Binary Codes
• Everything in memory is encoded using collections of bits.
Computer Software Binary Codes
• The letter “a” is represented in memory as 0110 0001.– This is an example of a bit string.– Note that it uses eight bits - a byte.
Computer Software Binary Codes
• The number 7 is represented as 0000 0111.
Computer Software Binary Codes
• Even the instructions the computer uses are bit strings. – The instruction to add two numbers for a particular
machine might be 1011 1011.
Computer Software Machine Language
• To program the first computers, programmers had to enter the binary strings themselves. – Programs in this form are called machine
code.
Computer Software Machine Language
• Here is a sample of machine code:
01001010010011100110011100000011111101010110101000011000100100010000111111001010001111010011110111110000011110010100011110100111101111011000000000011111101011100100100101110010000000111111010111001001001100100110011011011100111011110111110000000
Computer Software Machine Language
• For anything but tiny programs, this was a terrible burden.
• It was easy to make typos• References to data in memory had to be to
the numeric address of that memory location (i.e. the piece of information in location 1001 0101 1111 0100)
Assembly Language
Computer Software Assembly Language
• Shortly thereafter, someone wrote a program called an assembler.
Computer Software Assembly Language
• An assembler takes a file that contains names for the machine instructions.
• It then translates this into the machine code.• For example,
– Instead of 1011 1011 the programmer would write ADD for the add instruction.
– Programmers could refer to data locations by names (labels, e.g. SUM), instead of by numeric address
Computer Software Assembly Language
• Here is a sample of assembly language code:
CLR SUMMOV #TAB, R4
LOOP: TST (R4)BEQ ENDADD (R4), SUMADD #2, R4BR LOOP
END: HALT
Computer Software Assembly Language
• Easier than machine language, because it uses names for instructions and data locations.
Computer Software Assembly Language
• But, because computers’ instructions are so simple, it takes large numbers of them to do even a simple operation.
Computer Software Assembly Language
• This is especially true if they involve reading information from the keyboard or disk or writing it out to the monitor or disk.
• So, even simple assembly language programs are ridiculously long.
High-level Languages
Computer Software High-Level Languages
• High level languages (HLLs) were invented that substitute English-like commands for tens or even hundreds of machine instructions.
Computer Software High-Level Languages
• HLLs make the computer much easier to program. – Statements can be made much more
humanly intuitive than the machine's native instructions.
Computer Software High-Level Languages
• Also, the same HLL program can be used on different machines, with different machines languages.
• This is known as portability.
Computer Software High-Level Languages
• There are hundreds of HLLs. – Thousands?
• Some of the first were – FORTRAN, – COBOL– LISP
All of these are still used today.
Computer Software High-Level Languages
• Other popular languages include – ALICE– BASIC– Pascal– Modula– C– Prolog– Java
– C++– Perl– Python– Ruby– Macro languages – Scripting languages– And many, many more
Computer Software Computer Software
• High-level languages make the programmer’s life easier.– Relatively speaking
Computer Software Computer Software
• A sample HLL (Perl) program:#!/usr/bin/perl -w
# Input the valueprint "Enter a numeric value: ";$value = <>;chomp $value;
# Is it positive, negative or zero?if ($value > 0) {
print "$value is positive.\n";} elsif ($value < 0) {
print "$value is negative.\n";} else {
print "$value is zero.";}
Module Eight
Attacking Software
Attacking Software Attacking Software
• How applications work, and how they can be attacked.
Attacking Software Attacking Software
• The fundamental point is that a malicious piece of software does the same kinds of things that a legitimate one does.
• The only difference is that its purpose is usually harmful to the computer or its user.
Attacking Software
Application-Based Security Attacks
• If a malicious piece of software gets on your computer, it can use the computer’s own instructions and resources against you.
• Many familiar types of computer attacks do just this:– Trojan horses– Viruses
Attacking Software Attacking Software
• How malicious software uses your own computer for its purposes can be shown in a series of examples.
Search
Attacking Software
Search• A helpful feature on modern computers
is the search function.• It allows you to type in a word or
phrase.• The computer can then check to see if
that word or phrase is – part of a file name, or – part of the contents inside one of your files.
Attacking Software
Search• How it works -• Suppose you asked the computer to
search for a specific word (e.g. iPod) in your “My Documents” folder.
• The computer will search all of the data in all of those files for values matching “iPod” and will show you all files with that word in them.
Attacking Software
Search• Even though modern disk drives can
store hundreds of gigabytes of information, computers are fast enough to make even comprehensive searches of a computer’s files practical.– This is helped by the fact that computers
can keep track of (index) this information to make search even faster.
Attacking Software
Search• The ability to search your own files is
definitely something positive.
Attacking Software
Search• However, a malicious piece of software can
also search through your files.• It can look for pieces of information that look
like – Email addresses– Credit card numbers– passwords
• Once found, those data can then be sent back to the attackers.
Attacking Software
Search• A malicious search works the same way as a
legitimate one.• There is no difference from the point of view
of the computer.
• The only difference is whether the search result is beneficial or harmful for you.