Securing the Channel.

Slides:



Advertisements
Similar presentations
Point3r$. Password Introduction Passwords are a key part of any security system : –Work or Personal Strong passwords make your personal and work.
Advertisements

Authenticating Users. Objectives Explain why authentication is a critical aspect of network security Explain why firewalls authenticate and how they identify.
Cryptography Chapter 7 Part 4 Pages 833 to 874. PKI Public Key Infrastructure Framework for Public Key Cryptography and for Secret key exchange.
Networks. User access and levels Most network security involves users having different levels of user access to the network. The network manager will.
By: Mr Hashem Alaidaros MIS 326 Lecture 6 Title: E-Business Security.
1 Supplement III: Security Controls What security services should network systems provide? Confidentiality Access Control Integrity Non-repudiation Authentication.
Two-Factor Authentication & Tools for Password Management August 29, 2014 Pang Chamreth, IT Development Innovations 1.
CMSC 414 Computer and Network Security Lecture 12 Jonathan Katz.
Client/Server Computing Model of computing in which very powerful personal computers (clients) are connected in a network with one or more server computers.
70-293: MCSE Guide to Planning a Microsoft Windows Server 2003 Network, Enhanced Chapter 9: Planning and Managing Certificate Services.
It’s always better live. MSDN Events Security Best Practices Part 2 of 2 Reducing Vulnerabilities using Visual Studio 2008.
Secure communications Week 10 – Lecture 2. To summarise yesterday Security is a system issue Technology and security specialists are part of the system.
Information Networking Security and Assurance Lab National Chung Cheng University The Ten Most Critical Web Application Security Vulnerabilities Ryan J.W.
Cookies COEN 351 E-commerce Security. Client / Session Identification HTTP does not maintain state. State Information can be passed using: HTTP Headers.
CRYPTOGRAPHY PROGRAMMING ON ANDROID Jinsheng Xu Associate Professor North Carolina A&T State University.
Lecture 12 Electronic Business (MGT-485). Recap – Lecture 11 E-Commerce Security Environment Security Threats in E-commerce Technology Solutions.
Lecture 7 Page 1 CS 236 Online Password Management Limit login attempts Encrypt your passwords Protecting the password file Forgotten passwords Generating.
CS 4720 Security CS 4720 – Web & Mobile Systems. CS 4720 The Traditional Security Model The Firewall Approach “Keep the good guys in and the bad guys.
Jim McLeod MyDBA  SQL Server Performance Tuning Consultant with MyDBA  Microsoft Certified Trainer with SQLskills Australia 
Troubleshooting Windows Vista Security Chapter 4.
Protecting Internet Communications: Encryption  Encryption: Process of transforming plain text or data into cipher text that cannot be read by anyone.
Types of Electronic Infection
Protecting Students on the School Computer Network Enfield High School.
All Input is Evil (Part 1) Introduction Will not cover everything Healthy level of paranoia Use my DVD Swap Shop application (week 2)
PHP Secure Communications Web Technologies Computing Science Thompson Rivers University.
Chapter 12: How Private are Web Interactions?. Why we care? How much of your personal info was released to the Internet each time you view a Web page?
Network Security Continued. Digital Signature You want to sign a document. Three conditions. – 1. The receiver can verify the identity of the sender.
Database Security Cmpe 226 Fall 2015 By Akanksha Jain Jerry Mengyuan Zheng.
© Copyright 2009 SSLPost 01. © Copyright 2009 SSLPost 02 a recipient is sent an encrypted that contains data specific to that recipient the data.
Private key
Password Security Module 8. Objectives Explain Authentication and Authorization Provide familiarity with how passwords are used Identify the importance.
 Encryption provides confidentiality  Information is unreadable to anyone without knowledge of the key  Hashing provides integrity  Verify the integrity.
1 Web Technologies Website Publishing/Going Live! Copyright © Texas Education Agency, All rights reserved.
Department of Computer Science Chapter 5 Introduction to Cryptography Semester 1.
1-way String Encryption Rainbows (a.k.a. Spectrums) Public Private Key Encryption HTTPS Encryption.
SSL: Secure Socket Layer By: Mike Weissert. Overview Definition History & Background SSL Assurances SSL Session Problems Attacks & Defenses.
1 Internet data security (HTTPS and SSL) Ruiwu Chen.
Lecture 19 Page 1 CS 236 Online 6. Application Software Security Why it’s important: –Security flaws in applications are increasingly the attacker’s entry.
Why Does The Site Need an SSL Certification?. Security should always be a high concern for your website, but do you need an SSL certificate? A secure.
Unit 3 Section 6.4: Internet Security
Chapter 40 Internet Security.
Network Security Presented by: JAISURYA BANERJEA MBA, 2ND Semester.
SSL Certificates for Secure Websites
Encryption 1-way String Encryption Rainbows (a.k.a. Spectrums)
PAYMENT GATEWAY Presented by SHUJA ASHRAF SHAH ENROLL: 4471
Password Management Limit login attempts Encrypt your passwords
NETWORK SECURITY Cryptography By: Abdulmalik Kohaji.
Chapter 8 Building the Transaction Database
Chapter 5: The Art of Ensuring Integrity
Jim Fawcett CSE686 – Internet Programming Summer 2005
Web Services Security.
Uses Uses of cryptography Lab today on RSA
12. Encryption on the Internet
Introduction to Networking
Using SSL – Secure Socket Layer
Security.
Topic 5: Communication and the Internet
Web Systems Development (CSC-215)
Pooja programmer,cse department
Created by : Ashish Shah, J.M. PATEL COLLEGE OF COMMERCE
Introduction to Computers
Created by : Ashish Shah, J.M. PATEL COLLEGE OF COMMERCE
Security.
Unit 32 Every class minute counts! 2 assignments 3 tasks/assignment
Designing IIS Security (IIS – Internet Information Service)
Electronic Payment Security Technologies
Module 4 System and Application Security
Instructor Materials Chapter 5: Ensuring Integrity
6. Application Software Security
Fast-Track UiPath Developer Module 10: Sensitive Data Handling
Presentation transcript:

Securing the Channel

Overview… Security Breaches Security Considerations Types of Attacks Social Engineering Brute Force Attacks Password Protection Choosing a strong password Login Systems Password storage security Encryption and Hashing Firewalls IP Filtering

Introduction This module makes no claim in providing a definite claim in securing your web applications. This lecture will cover as much relevant material as I can with practical solutions. The plan is to take apart the DVD swap shop and identify the weaknesses and making recommendations on how to improve the security.

Security Breaches At some point each website will need to manage some form of user input. Log In forms. Registration. Search This should be fine in perfect world. However inevitably this attracts the wrong kind of attention. Why? Passwords, Credit Card information.

Pillars of Security In regards to security there are three pillars of security. Confidentiality This is the privacy of the data that is being stored on the system. This will include personal details, credit card information Preventing someone from reading information that they are not authorised to read. Integrity Preventing data from being modified without the proper credentials or authorisation. Can be compromised through accidental events. Availability Losing access to data or service e.g. Email, Ecommerce.

Security Considerations There are also three main areas to look ay in regards to security. Secure Communication Prevents third parties from accessing the data. Includes physical security of server and data as well as the communication channel. Authentication Identifying who is accessing the system. They are who they say they are. Authorisation Only allowed access to certain areas of the web application. Permissions after authentication.

Types of attacks We will consider some common types of attacks:- Injection Attacks Social Engineering attacks Data interception (e.g. Packet Sniffing) Brute Force Attacks Dictionary Attacks We are going to look at some issues to consider when securing the channel, some technical and some that are common sense. Problem is there is little of it about.

Be careful who you talk to? Just by a general conversation what can you learn about a person? Pet names? Mothers maiden name Place of birth First school

Selecting Passwords We tend to select passwords based on something we can remember. This is only natural. By people knowing more about us, it allows our passwords to be guessed easier. Guess the password? T _ _ _ _ S Developers can only protect the users so much.

Login The most obvious form of authentication is with the use of a login form. The user is usually identified by either an email address/ username and password. In this case… A simple method of securing the password is by hiding each character by an asterisk. This prevents the use of shoulder surfing. Even without insider knowledge the potential of guessing passwords is still possible.

Dictionary Attacks This is pretty much what it sounds like. It makes use of a dictionary and attempts each password on a valid username in the hopes one of them is correct. You would be surprised how many people have a very common password. Kali contains a password file called rockyou.txt and contains 9,606,665 passwords. That’s a lot…

Brute force attack Dictionary attack is a type of brute force as it tries each password in order until the correct one is found. If we know the length of the password we can create different combinations of characters until the password is found. If the password was ‘CC’ all we know it is two characters long. We would cycle through:- AA, AB, BA, BB, BC, CB, CC Until we got the correct one. Longer the password the longer it would take to crack.

Password Protection So how can we increase the password security? Developer: Set Required Password length Set required characters for password Prevent too many login requests Password expiration Users: Educate Users on password creation Longer passwords Letters (Uppercase and Lowercase) Numbers Symbols Spaces (if applicable)

Password Prefix A good method to adopt is the use of prefix passwords. This is where you have a set password that you use such as JL67%ghR89() This is then modified to adopt the website you are on. E.g. JL67%ghR89(facebook) JL67%ghR89(youtube) JL67%ghR89(twitter) This way your passwords are different to every site. As a lot of people use the same password.

Choosing a strong password Line from favourite song. Iw2BF()Fm&Q

Choosing a strong password Line from favourite song. Iw2BF()Fm&Q I want to break free - Freddie Mercury and Queen Line from favourite movie. WaFtS?C_Sp&nF

Choosing a strong password Line from favourite song. Iw2BF()Fm&Q I want to break free - Freddie Mercury and Queen Line from favourite movie. WaFtS?C_Sp&nF Want anything from the shop? Cornetto - Simon Pegg & Nick Frost YkNJS_W1c-G0t

Choosing a strong password Line from favourite song. Iw2BF()Fm&Q I want to break free - Freddie Mercury and Queen Line from favourite movie. WaFtS?C_Sp&nF Want anything from the shop? Cornetto - Simon Pegg & Nick Frost YkNJS_W1c-G0t You know nothing, Jon Snow_Winter is coming - Game of Thrones

Writing login systems When creating login systems we can use various options… We can use an off the shelf security solution We can create our own Examples of off the shelf security solutions are:- Windows Authentication Forms Authentication

Windows Authentication This makes use of groups and users set up on the windows machine that the web application is running from. In order to add new users it must be done by an administrator of the machine. This is useful if it is local but not for a web application as you could see why. Most web application have a page that allows the user to create an account. Due to this being local, this would not be a viable method to create a user for a web application.

Sign up form

Forms Authentication DIY Authentication Using the form authentication built into .NET provides a set of tools that help you create a login, sign up and change password pages. Creating your own allows you know how it works and is customisable. But if it goes wrong whose fault is it? DIY Authentication

Securing Stored Passwords Passwords need to be secured in the Data layer as well as the Presentation layer. In the DVD swap shop the user table displays the passwords in plain text.

App_Data Folder In visual studio it places the database within the App_data folder. This is a secure location that prevents the database being accessed through the browser. Using the URL of http://localhost:49597/DVDSwap/App_Data/dvd.mdb By using this it makes the database more difficult to download.

Encryption vs Hashing Encryption Hashing Process of encoding a message using a key that can only be read by authorised users. Allows a key to be used to decrypt the encrypted data and be seen again in plain text. Symmetric/Asymmetric Encryption Hashing A one way encryption method that is used for passwords, credit card information and anything deemed sensitive to the developers. Prevents the data from being reversed. Can be compared against.

.NET Cryptography .NET provides a name space that handles the hashing of data. System.Security.Cryptography As hashing is one way it is hard to know what the original value was. Password 5E884898DA28047151D0E56F8DC6292773603D0D6AABBDD62A11EF721D 1542D8 This is a much better method of storing passwords within a database as they can not be reversed engineered. When checking a users password, a new hash is created and it the hash matches then the user becomes authenticated.

Salt If a hacker gets access to the database they can apply the hash to their dictionaries and find the hashed password by discovering the hashing algorithm used. These new dictionaries are known as rainbow tables. Adding salt will make the hash much harder to decipher. Salt consists of extra data added to the data such that we are not just hashing the password. Salt is random data that is added to the string which is then hashed. The idea of salt is to defend against dictionary attacks against its hashed value.

Salt So what if we had two users with the same password? John 5E884898DA28047151D0E56F8DC6292773603D0D6AABBDD62A11EF721D1542 D8 Fred 5E884898DA28047151D0E56F8DC6292773603D0D6AABBDD62A11EF721D1542 D8 Lets add salt… John C0C1664CC490D0FD9CE0BA81035B9199248AD16426301F03A70A4DECCDDD 5990 Fred 9Wo0irC6+92F45AC854246D5A272B8FDB620B48F32230D3FF509299AB07BC62 C7396BAFB7

Securing the Communication Channel So we have looked at securing the presentation layer and data layer so what about the communication itself? As we know HTTP is passed between server and client in an unencrypted form. This allows the use of packet sniffing to intercept the communication being transmitted, Client Server Data channel plain text data Client Server

Encrypting Data When encrypting data for transmission, how does the recipient get the key? At some point I must send the key over the channel which will still allow the attacker to intercept the data being sent as the key is located within the message. Client Server Message + Key Client Server

Public and Private Keys Public and Private keys are used within asymmetric encryption. A private key is personal to the user and only the user. A public key is accessed by the sender. Before sending data it’s encrypted using the recipients public key. This is then sent to the recipient. Once received, the message is decrypted using the recipients private. This prevents interception from being possible as they do not possess the private key being used for decryption. Client Server Private key (decode) Message + public key (encode only!)

Secure Socket Layer (SSL) SSL uses a system of public and private keys to encrypt the data. The browser makes a secure HTTP request HTTPS on port 443 The server sends back a digital certificate verifying its credentials The client verifies the certificate with the issuing agency Using the public key data is encrypted between client and server Certificates are used for authentication of a trusted source. These are issued by the certificate authority. SSL setup is simple but an approved certificate by the CA is costly. These can be self signed and allow for SSL but generate the following error.

Validation – All input is Evil Who do you trust? You have all signed up on G677 which means I know a great deal about you all. What if I used that data? Do you trust the application you are using to help with your assessment? Entering data is one way of our applications gathering data but what about from external sources? What if we use another site? Are there systems as secure as yours? What if you download XML from another source and it happens to contain harmful scripts or SQL injection code?

Firewalls Attacks make use of a port scanner that scans the IP address for all open ports from 1 – 65535. Open ports are then probed to see what services the port is used for and check if a connection can be made. NMAP is a tool that is used to check all open ports on a system. A firewall restricts access to servers and services on a network by monitoring ports and only allowing authorised users to access these servers or services. This reduces the surface area of the machine and aids in prevention of an attack.

IP Filtering Alongside encrypting the data stream we should also control the machines that access the server through HTTP requests. Filters allows us to allow and deny access to the server through IP ranges. This could be to only allow access to the server through a valid DMU IP address. Access from other addresses would be completed on a case by case basis. Internet Information Services (IIS) enforces a reverse DNS lookup. A reverse DNS lookup checks the IP address of the HTTP connection and verifies if it is in fact part of the domain it claims to be in.

Unused Services The rule here is if you don’t use it, turn it off! The default position with software such as Windows Server is to have pretty much all services unavailable. You turn then on as you need them. In the case of Windows Server 2008 you cannot even browse the internet without being asked security questions.

Permissions During development, permissions are usually set to maximum so you are not firefighting when developing. When deployed these permission should be set to minimum to prevent unauthorised access to data that users are not authenticated to view. In regards to SQL, If the user only needs to view information then only give them permissions to read. They have no need to Write and Delete.

Recap… Security Breaches Security Considerations Types of Attacks Social Engineering Brute Force Attacks Password Protection Choosing a strong password Login Systems Password storage security Encryption and Hashing Firewalls IP Filtering