Global Information Assurance Certification Paper Copyright SANS Institute Author Retains Full Rights This paper is taken from the GIAC directory of certified professionals. Reposting is not permited without express written permission. A comparative study of attacks against Corporate IIS s. and Apache Web Servers t gh GIAC (GCFW) Gold Certification i lr Author:  Craig  S  Wright,  craig.wright@information-­‐defense.com   ul Advisor:  Antonios  Atlasis   f ns ai Accepted:  20  July  2011   et rr ho Abstract   It  has  been  suggested  that  an  attacker1  will  specifically  target  the  Windows   t operating  system.  This  research  has  shown  that  rather  than  this  being  the  case  an   Au attacker  will  in  fact  not  target  Microsoft  Windows,  but  rather  seeks  to  avoid   attacking  Linux.  This  study  has  shown  significant  support  for  the  assertion  that  an   e, attacker  shies  away  from  Linux  and  not  that  they  aim  to  attack  windows.  In   ut particular,  this  study  was  designed  to  collect  data  on  attacks  against  corporate  Web   servers.  Unlike  many  of  the  other  proceeding  studies  using  honeypot  systems,  this   t i t experiment  was  designed  to  collect  information  on  attacks  against  "secured"   ns corporate  systems.     I NS SA 11 20 ©                                                                                                                 1    The  Term  “Attacker”  has  been  used  in  this  paper  to  refer  to  the  commonly  used  designations   of  “hacker”  or  “cracker”  and  covers  anyone  attacking  the  computer  host.   nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 2       1 Introduction s. It has been suggested that Microsoft Server Software is more likely to be attacked t than Linux (Broersma, 2005) due to perceived insecurities within these systems. Previous gh research has focused on investigating the trends2 against the underlying operating system i lr as a whole (Honeynet Project & Research Alliance, 2005b, 2005a). The purpose of this ul research was to investigate a single factor, namely, the Web server software as a vector f for attack. ns ai This project was not designed to test the relative strengths or security levels of et either Operating System, but rather to determine the relative attractiveness of each of rr these systems (the system being the combination of the web server and the underlying O/S) to an attacker. ho t In this experiment, the systems were configured to appear as a financial services Au organisations client website. There were two systems, one running on Apache and the e, other on IIS. All other services have been firewalled and only access to the web server ut using HTTP (TCP port 80) and HTTPS (TCP port 443 over SSL) was allowed. The t i actual pages and data presented by the web servers were identical but for the server t ns headers. Unlike previous research, the focus of the experiment was to record the volume I of attacks from individual sources. By this process, we were able to answer the following NS questions: SA 1. Which web server software product (IIS or Apache) will have the most “vulnerability scans”3? 11 2. Which product will an attacker spend the most time with in an attempt to “break” 20 or “crack” the software security settings? ©                                                                                                                 2    The  “Know  your  enemy  –  Trend  analysis”  from  “The  HoneyNet  Project”  has  spawned  several   side  projects  and  more  in-­‐depth  honeynetworks  designed  to  analyze  and  record  attacks  (Honeynet   2004a,  2004b).     3    A  Scan  is  defined  as  a  single  attempt  to  gain  information  on  the  system  from  a  single  host  for   the  purpose  of  this  experiment.  This  includes  fingerprinting  the  application  as  can  be  done  using   either  a  vulnerability  scanner  or  another  tool  that  analyses  the  service  version.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 3       3. What is the subsequent effect of hiding the host headers4 on the servers? s. 2 Methodology used in the study t The research was based on a controlled trial with naturally randomized subjects. gh The honeypot design without notification allowed for the randomised discovery of the i lr systems used in the tests. This naturally excluded targeted attacks from this study as the ul systems: f ns 1. Only simulated real banking sites. ai 2. Had not been available for a sufficient amount of time to be replicated in et search engines. rr A robots.txt file excluding all search engines and the Internet Archive was ho implemented to act as if the system was not allowing caching. This was added to stop t Google scans and similar intelligence gathering methods as these could bias the Au experiment. This was designed in part to cover the fact that the real system was not e, available before the start of the experiment. tut By restricting access to the servers through a firewall to only the Web service on i t TCP ports 80 and 443 it was possible to demonstrate system attractiveness on a single ns defined service. The results of this experiment support the research efforts of the I HoneyNet Project (HoneyNet Project & Research, 2005), Symantec (Symantec, 2004), NS and the Internet Storm Centre (The SANS Institute, 2005). In correlation to the prior SA research on this topic it was initially confirmed that a greater number of attacks were made against the Windows server. 11 Rather than focus on the survivability of a host, this experiment has been designed 20 to determine the attractiveness of the host to an attacker. Unlike many of the experiments © on this topic, which have preceded this one, the experiment has been designed to test the effect of obscuring the servers by hiding the host headers and information thus available to an attacker.                                                                                                                 4    This  is  the  HTTP  Server  host  header.  Both  IIS  and  Apache  allow  an  administrator  to  change   or  “hide”  this  system  field.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 4       The interesting effect shown in this study was not that IIS on Windows was more attractive than Apache on Linux, but rather that Linux is less attractive to attackers. The reasons for this have not been determined conclusively, but it would seem that LAMP5 s. based systems where less attractive than IIS, MSSQL and .Net based implementations. t gh For the purpose of this paper we have not tested the effects of Apache on Windows which i would make an interesting follow-up test. lr ul The amount of time and effort an attacker spends on a particular system cannot be f used to determine the difficulty in attacking that system. Attractiveness is not the same as ns survivability and a follow-up test was conducted using a perceived vulnerability in both ai Windows and LAMP. et rr The follow-up test involved configuring the system to appear as if it had vulnerability as defined by a Nessus scan. A collection of IIS 7 and Apache ho vulnerabilities were simulated. These vulnerabilities were selected randomly from the t Au CVE list and were simulated using HPING (see appendix 5) and Snort (see the Snort Manual6) to modify the packets returned by both servers such that they mirrored the e, ut responses of a vulnerable system. The vulnerable versions of the software were not used t as it would not be possible to control for individual responses (most vulnerable software i t versions can be attacked in a number of ways). This was used to differentiate attacks ns I from Worms and Users. The traffic was filtered using SNORT to both record the data as NS well as to determine and monitor attacks. SNORT allows for the creation of automated packet responses. Using the React SA function defined in section 2.11.4 of the SNORT Manual, a honey pot style web page can 11 be fashioned for just the selected attack making the attacker believe they have discovered a vulnerable system. 20 For instance, in the alert rule for cve.2009-4444: ©                                                                                                                 5   Linux,  Apache,  MySQL,  PHP   6     This  is  covered  in  Section  2.11.4  (React)  of  the  SNORT  manual  (from   http://www.snort.org/assets/166/snort_manual.pdf).  In  place  of  a  default  403  forbidden  page,  a   "DEENIABLE_REACT"  can  be  configured  in  the  rules  using  a  simulated  vulnerable  page.  So  when  an   alert  is  generated  for  an  attack,  it  can  be  used  to  create  a  special  web  page  as  a  honeypot.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 5       alert tcp $EXTERNAL_NET any -> $HTTP_SERVERS $HTTP_PORTS (msg:"ET WEB_SERVER Possible Microsoft Internet Information Services (IIS) .asp Filename Extension Parsing File Upload Security Bypass Attempt (asp)"; flow:established,to_server; content:".asp|3B 2E|"; fast_pattern:only; s. nocase; http_uri; classtype:web-application-attack; sid:2010592; rev:8;) t gh Will be altered to add a "react" statement as follows: i lr alert tcp $EXTERNAL_NET any -> $HTTP_SERVERS $HTTP_PORTS (msg:"Customed message associated with the expected response...)"; ul flow:established,to_server; content:".asp|3B 2E|"; fast_pattern:only; f nocase; http_uri; classtype:web-application-attack; sid:2010592; rev:9; react: block;) ns The block statement stops the page hitting the original target and send it to either ai et a single default page or other alternate pages if these are configured. rr To enable this, SNORT needs to be built with the following build option (also, the ho --flexresp compile option is required): t ./configure --enable-react / -DENABLE_REACT Au Then, the page can be configured to read from a file. e, config react: ut or in our case to read from a customised file which is configured to return the t i t same format as the attacker would obtain if attacking the site successfully: ns I config react: NS When configuring this option, it is critical that the file must contain the entire response, including any HTTP headers. Images and other information used in building SA the fake page can be located on an alternative server and the "block" page should appear 11 as the error being modelled7. 20 Note that the file must contain the entire response, including any HTTP headers. But, this response is not stringently limited to HTTP. It is also possible to craft a binary © payload of arbitrary content if this is the expected response from the attack.                                                                                                                 7  A  separate  paper  on  the  creation  of  these  pages,  Inline  redirection  and  the  use  of  HPING3  to  replay   packets  and  to  create  a  SNORT  Honeypot  is  being  developed  and  written  by  the  author  of  this  paper   and  should  be  ready  soon  after  this  paper  is  loaded  and  published.  This  paper  will  also  detail  the  use   of  IPTables  and  Snort  Snarf  to  redirect  packets  on  the  fly.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 6       Further, a "%s" is used in the rules to load the SNORT "msg" extension to the react rule and this can be used to load customised responses based on details about the selected attack, data called in the attack and more. Here, the "react" statement would be s. entered as: t gh react: block, msg;) i lr Here the defaul message in snort also need to be changed from: ul ::= \ f "You are attempting to access a forbidden site.
" \ ns "Consult your system administrator for details."; ai To something more appropriate to the response that the attack would be expected et to elicit. rr 2.1 hoDescription of experimental study Subjects (i.e. the attackers) discovered the systems based on their own activities. t Au As there is no way to attract Subjects to the systems, it was expected that a random sample of the population of “hackers” on the Internet would find and explore the system e, at any given time. No details of the source of the attacks were analysed. These details ut (including attack sources, IP addresses and browser header information) have been t i t recorded for later analysis. ns I The analysis took the nature of the probes into account as well as the relative NS amount of time spent on each system. SA 3 Experimental procedure 11 The data collected from this experiment is based on two “honeynets” deployed to 20 appear as the primary and Disaster Recovery (DR) site for a fictitious financial organisation. Each HoneyNet consisted of two servers configured to run VMWare. Each © of the VMWare servers was configured to run a Web server using bridged network access. The first virtual server was configured using Red Hat Enterprise Linux 6.0 and Apache version 2.2. The second virtual server consisted of a Windows 2008 server Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 7       system running IIS 7.0. Each of the pages was configured to appear as a client portal in our fictitious financial services organisation (Figure 1). s. t igh lr ul f ns ai et rr ho t Au e, t iut t ns Figure 1 - The "Staff Credit Union" banking login page I This organisation was created through an amalgamation of existing Credit Union NS and Banking sites and was designed to look and feel as "real" as possible. The domain SA was not formally registered, but a DNS zone was created on the local server. This zone and domain were never published nor were they advertised. 11 To simulate a financial services organisation, these systems were installed behind 20 a firewall, which only allowed access to TCP port 80 and a simulated access to TCP port 443 when authenticated. The HoneyNet was linked to “real”8 servers from a fictitious © organisation. Both Systems were configured to require authenticated access before allowing any access to a backend application.                                                                                                                 8    These  systems  will  be  running  the  software  being  tested  though  they  will  have  no  real   function.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 8       Using the Snort IDS9 software, the number of attacks and thus the effort expended by an attacker on each server was measured and recorded. The open source IDS product, SNORT10, was used to collect the data. SNORT was installed on the underlying operating s. system that hosted the virtual machines as well as running the IPTables firewalls. A t gh separate monitoring server was run on a Spanned switch port. The underlying system was i Redhat Enterprise Linux 6.0. The Redhat system was configured with an IP address that lr ul could not be routed to the Internet and which was monitored for access (no access or f compromise was noted in this system). In this manner, it was not possible to detect the ns IDS deployment from the web server. All systems where patched fully before being ai deployed (See Appendix 2 for statistics on the patching of deployed systems). et There were two phases to the first stage of the experiment with the first phase rr involving leaving the web host headers unaltered. The second phase involved hiding the ho web host headers. By this, the server was stopped from advertising its software version. t In the first phase, the systems responded as Apache version 2.2 and IIS 7.0. In the second Au phase, both systems where configured to respond with “Secure Web Server version 9.3”. e, ut No other changes were made and a determined attacker using P0F or NMap could t have differentiated the IP packet information to determine a difference between a Linux i t or Windows system (as a guess). ns I The results were collected daily for the period of the test11. Informational data was NS excluded from the results. All attacks detected by SNORT were collected together and no effort has been made to correlate the levels of attack against each server. The Monitoring SA server was used to collect all network traffic to and from the servers. The switch was 11 spanned on the Monitoring Server port and TcpDump was set to capture all traffic. This was set as both a backup for the Snort systems as well as means of collecting any attacks 20 that had been made against systems that could have bypassed Snort. ©                                                                                                                 9    IDS  –  Intrusion  Detection  System   10    For  details  on  Snort  and  to  be  able  to  download  and  register  see  Http://www.snort.org     11    The  test  was  conducted  from  February  2010  to  December  2010.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 9       Shared  Data Store s. t Internet   Virtual  Web  Server Windows  2008  IIS Virtual  Web  Server ISP gh Red  Hat  Linux 203.x.x.x Apache 203.x.x.x i lr VMWare  Server VMWare  Server Linux Linux ul 10.x.x.x 10.x.x.x f ns Cisco  Router Cisco  Switch Setup  with  2   ai Firewall  System VLANs et rr ho t Monitoring  system 10.x.x.x Au Figure 2 - Network Diagram e, Future research and analysis to correlate the levels of attacks and statistically ut analyse the intensity of attacks against each server as a function of time is planned. t i t 3.1 Steps to physically control variation ns In order to minimise variation, the HoneyNet Servers were configured as follows; I NS • Both systems were installed on matching hardware and domain addresses, • Both systems were booted from a Live DVD based created using RHEL in the SA manner of a Knoppix distribution. 11 • Both systems resided on the same switched network and be active at the same 20 times. © • The IDS system was not be available or visible to the external network. • Results were randomized as the systems were not “advertised” and it is expected that they were by general network scans and probes. Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 10       • The IP12 addresses of the systems were sequentially allocated such that a probe could detect both at the same time. s. 3.2 Steps to statistically control variation t When either system was attacked by a DoS or DDoS13 attack, both systems were gh made unavailable using IPTables. Snort was configured to trip a default block rule that i lr took effect on both systems for any IP address that was noted as attempting a DoS or ul DDoS by Snort. This was done as the test was not designed to determine DoS/DDoS f ns situations and it was decided that it was better to not continue to record data on one ai system while the other is not being tested. et The Honeypots were deployed using the methodology detailed in the paper by rr Greg M. Bednarski and Jake Branson (2004) titled, “Information Warfare: ho Understanding Network Threats through Honeypot Deployment”. t Au 4 Results and Discussion e, We subsequently analysed the data based on the average number of individual ut source hosts and attacking each system and the number of individual attacks registered t i t per host. If an attacker had been attacking from multiple systems (such as from the use of ns a Botnet), this was not determined and each attacking host was included individually. I The test was stopped following the collection of data for phase 1 of the test and NS the systems were no longer routed for a period of six weeks before a new IP address in SA the same C-Class range was allocated and the system was redeployed using a simulated and randomly selected vulnerability from the list of vulnerabilities. Vulnerabilities were 11 selected randomly from the CVE list (CVE14). The selected vulnerabilities used are 20 included in Appendix 1. ©                                                                                                                 12   Internet  Protocol   13   Denial  of  Services  (DDOS  is  a  Distributed  Denial  of  Services)  attack.   14   The  CVE  list  is  available  online  at  http://cve.mitre.org/data/downloads/allcves.html   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 11       The number of attacks registered per host 70.00 s. 60.00 t gh 50.00 i lr 40.00 ul Apache IIS f 30.00 ns 20.00 ai et 10.00 rr 0.00 Initial Test Phase Test with host Headers obscured ho t Figure 3 Phase 1 results of attacks against IIS and Apache (attacks / day)15 Au The systems were left running with the traffic being recorded to collect data for e, several weeks with the Web servers host headers remaining visible (Phase 1). Next, we ut reconfigured the servers to each display an alternate host header; “Secure Web Server t i t version 2.3” (Phase 2). This was designed to obscure the system details from a potential ns attacker.16 I NS IIS Apache Medium High Medium High 1090.1 2097.0 1242.5 1272.9 SA Table 1 Mean time spent attacking with Vulnerabilities (seconds) 11 The results of these tests have been displayed in figure 3. From the results we can 20 say that there are no statistical differences between attacks against the hosts when the host headers are obscured. In Table 1, the mean amount of time an attacker spent in © attacking the web service is displayed for CVE vulnerabilities. The high and medium                                                                                                                 15   See  appendix  3  for  the  definitions  of  Attacks  used  in  this  document.   16   Definitions  used  for  terms  such  as  an  Attack  within  this  document  are  included  in  Appendix   3  below.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 12       level ratings are determined using the CVSS17 rating (http://www.first.org/cvss/). In phase two, the average time per attacking IP address was recorded for both the s. simulated medium and high level attacks. Again we see a clear distinction between IIS t and Apache with attackers spending more time on IIS high level attacks (2097.0 seconds) gh than Apache high level attacks (1272.9 seconds). Phases are separated depending on if i lr the server headers have been changed or not18 ul f Average Source Hosts Attacking the Systems Daily ns 600.00 ai et 500.00 rr Apache IIS 400.00 ho t 300.00 Au 200.00 e, ut 100.00 t i t ns 0.00 Initial Test Phase Test with host Headers obscured I NS Figure 4 Phase 1 results of attacks against IIS and Apache From these results we can see that an attacker will extend significant effort SA against an IIS based system with a perceived high level vulnerability. 11 It would also be possible to posit an alternative explanation that the mean time 20 does not necessarily shows a preference, but also “difficulty” on exploiting the target. No evidence has been found that attacking IIS is significantly more difficult than attacking ©                                                                                                                 17    Further  information  on  this  rating  system  is  available  online.    For  a  detailed  description  of   this  rating  system  http://scap.nist.gov/events/2010/itsac/presentations/day1/SCAP_101-­‐ CVE_and_CVSS.pdf.  These  documents  are  not  directly  referenced  in  this  paper,  but  serve  as  a  valuable   introduction  to  this  rating  system.   18    The  two  phases  of  data  collection  are  separated  depending  on  if  the  server  headers  have   been  changed  or  not.  Phase  1  is  set  using  the  default  host  headers  for  the  web  server,  Phase  2   involved  changing  to  the  alternate  host  header;  “Secure  Web  Server  version  2.3”.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 13       Apache (or for that matter that Linux is less difficult than Windows to attack) and it is more likely that the difficulty of an attack is related to the individual vulnerability and not the underlying system. s. t In addition, the economics of an attack would likely lead to seeking the easier gh target if this was the case. In such an event, it would be logical to posit that given a i lr choice of a Linux or Windows based system, if Windows was "more difficult" to attack, a ul clear preference for Linux would be expressed with a lower time being spent on f Windows systems expressing the same data. ns ai 4.1 Apache is less attractive to attackers et The results of the experiment clearly demonstrate a similarity in the results rr obtained when the server type either is unknown or is determined to be a Microsoft ho Windows system. However, there was a markedly lower intensity and volume of attacks t against the Apache Web server when its host headers were displayed. Au Mean Daily Results e, Apache IIS ut Number of Number of Source Number of Number of t i attacks Hosts attacks Source Hosts t detected per Detected detected per Detected Per ns host Per Day host Day I Initial Test Phase 41.82 370.71 59.93 534.36 NS Test with host Headers obscured 58.43 540.86 59.54 536.93 SA Table 2 Mean attacks by day 11 In order to determine whether the Microsoft Windows IIS Web server or the 20 Apache Linux Web server would attract a larger number of scans or attacks than its counterpart, a two-sample t-test19 was performed on the "Number of Source Hosts © Detected per Day" (Figure ). When choosing a null hypothesis (Ho) that there is no difference between the Apache or IIS Web server, it was found that the results of the initial phase of the experiment were significantly different (t = 29.59, df = 54, p <                                                                                                                 19    See  appendix  4  for  a  detailed  description  of  the  statistical  tests  used  in  this  analysis.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 14       0.1507) at the alpha = 20 level20. Therefore we rejected the Null and accepted the alternative hypothesis HA, that there was indeed a difference between the servers. s. From the results there is evidence to support the hypothesis that the Apache Web t server on Linux is less likely to be attacked then IIS Web server on Microsoft Windows gh 2008. i lr ul 4.1.1 Attacks against Linux with Apache are less intense An ANOVA21 analysis of the results of the subsequent tests test demonstrate a f ns significant difference (F=5.4402; df = 3, p < 0.0019) in the intensity of the attacks. It can ai clearly be seen in Figure that an attacker stops an attack with less effort when it has been et determined that they are attacking Apache on Linux. rr A comparison of the number of attacks detected per host for both the obscured IIS ho server, and either server with the host headers altered demonstrated no significant t difference (F=0.0007; df = 2, p=0.9993). Au Again we reject the null hypothesis (Ho) that there is no difference between the e, server groups tested. Means Comparisons for all pairs using Tukey-Kramer HSD at alpha ut = 5 show that Apache Web servers are less likely to be attacked. t i t ns 4.1.2 Attackers treat unknown web servers as IIS I ANOVA Analysis of Attacks by source hosts when the header was not Apache on NS 2223 Linux demonstrated no significant difference (F=0.0007; df = 2; p=0.9993). SA ANOVA again supports the assertion that there is no significant variation (F=0.0344; p=0.8538, RSquare = 0.000859) when we compare the results of the phase 1 11 tests against IIS to the phase 2 tests with the host headers obscured24. 20 Conversely an analysis by ANOVA of the phase 1 tests against Apache to the                                                                                                                 © 20   A  higher  level  of  alpha  was  chosen  for  the  initial  test  as  a  lower  volume  of  data  had  been   collected  at  this  point.   21   A  number  of  statistical  processes  (including  ANOVA)  are  detailed  in  Appendix  4.   22   See  Appendix  4.   23   The  results  were  either  an  unknown  server  (based  on  the  hidden  host  header)  or  the  IIS  web   service.   24   The  two  phases  of  data  collection  are  separated  depending  on  if  the  server  headers  have   been  changed  or  not.  Phase  1  is  set  using  the  default  host  headers  for  the  web  server,  Phase  2   involved  changing  to  the  alternate  host  header;  “Secure  Web  Server  version  2.3”.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 15       phase 2 tests with the host headers obscured significantly (F=5.7659; p=0.0211, df =3) supports our claim that attackers are less likely to attack Apache on Linux. s. Further, when these results are coupled with the initial analysis (F=14.4513; t p=0.0004, df = 3) of attacks against Apache vs. IIS from above it is easy to see that there gh is support for the assertion that an attacker does not care what the server is as long as it is i lr not Linux.25 ul These results would suggest that the threat against Internet deployed hosts is f ns moving from automated scanning tools to more human intensive processes. By ai specifically avoiding the Apache Linux system (when not obscured), there is evidence to et support the contention that attackers are manually targeting systems and actively stopping rr attacks they deem to be “too difficult”. ho t 5 Limitations in this study Au No effort was made to analyse and the levels of attacks against any server. It may e, be that more high-level attacks are made against a Linux server for example; this ut assertion has not been tested. In this study, all levels of attack were treated equally t i whether they were designated as a low, medium or high-level attack. t ns As noted above, it would also be possible to posit an alternative explanation that I the mean time does not necessarily shows a preference, but also “difficulty” on exploiting NS the target. It would be necessary to create a separate experiment in order to collect SA evidence as to whether attacking IIS is significantly more difficult than attacking Apache (or for that matter that Linux is less difficult than Windows to attack) and it is more likely 11 that the difficulty of an attack is related to the individual vulnerability and not the 20 underlying system. © 6 Conclusions and Future Work Some potential areas of further research have emerged from this study. It is clear                                                                                                                 25   HO,  There  are  no  differences  between  the  number  of  attacks  against  a  server  type;     HA,  There  is  a  difference  between  at  least  one  of  the  tests.  Tests  conducted  at  the  alpha  =  5   level.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 16       that an attacker will avoid Linux servers that are not obscured, though this study can provide no reasons for this behaviour. A further and interesting test would be to use an Apache installed on a Windows server. That could be used to show if attackers avoid s. Apache or Linux. t gh It is suggested that researchers consider this study and its conclusions as an initial i lr exploration into the methodology of an attacker. Research into the motivations driving ul this behaviour in an attacker needs to be determined. Further research is essential in order f to develop appropriate strategies and measures to secure systems sufficiently. It is ns essential to understand the psychology of the attacker if effective controls are to be ai developed and deployed. et rr A study where the host headers on a Microsoft Windows IIS host are altered to simulate Apache on Linux could determine some further important results. ho t This study has shown that attackers are not so much attracted to Windows, but Au rather shy away from Linux based systems. e, One potential reason for this could be the increased W32 market penetration. ut Another possible reason could stem from a perceived greater level of security with Linux t i t hosts. The results of this study do not demonstrate that either Linux or Microsoft ns Windows is more secure. However, the results do support the claim that attackers believe I that Linux is more difficult to attack, as it is more secure. As the average attacker was NS willing to spend a greater amount of effort in an attempt to compromise a high SA vulnerability (Table 1) IIS Windows system when defined by the amount of time spent attacking the system, we can see that IIS has become a more attractive target for attackers 11 than LAMP based systems running the same data. 20 Further research is needed on this topic to determine “WHY” Linux is less attractive than Windows to attackers. In addition, experiments into the effects of using © other systems (such as the MAC OS) could be further explored. Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 17       7 Appendices s. 7.1 A list of the used vulnerabilities used t The  following  appendix  contains  a  list  of  vulnerabilities  used  in  the  experiment.   gh 7.1.1 Apache Vulnerabilities i lr CVE-2010-4172 Multiple cross-site scripting (XSS) vulnerabilities in the ul Manager application in Apache Tomcat 6.0.12 through 6.0.29 and 7.0.0 through 7.0.4 f allow remote attackers to inject arbitrary web script or HTML via the (1) orderBy or (2) ns sort parameter to sessionsList.jsp, or unspecified input to (3) sessionDetail.jsp or (4) ai et java/org/apache/catalina/manager/JspHelper.java, related to use of untrusted web rr applications. ho t CVE-2010-2068 mod_proxy_http.c in mod_proxy_http in the Apache HTTP Server 2.2.9 through 2.2.15, 2.3.4-alpha, and 2.3.5-alpha on Windows, NetWare, and Au OS/2, in certain configurations involving proxy worker pools, does not properly detect e, timeouts, which allows remote attackers to obtain a potentially sensitive response ut intended for a different client in opportunistic circumstances via a normal HTTP request. t i t CVE-2010-1587 The Jetty ResourceHandler in Apache ActiveMQ 5.x ns before 5.3.2 and 5.4.x before 5.4.0 allows remote attackers to read JSP source code via a I // (slash slash) initial substring in a URI for (1) admin/index.jsp, (2) admin/queues.jsp, or NS (3) admin/topics.jsp. SA CVE-2010-1452 The (1) mod_cache and (2) mod_dav modules in the Apache HTTP Server 2.2.x before 2.2.16 allow remote attackers to cause a denial of 11 service (process crash) via a request that lacks a path. 20 CVE-2010-0009 Apache CouchDB 0.8.0 through 0.10.1 allows remote © attackers to obtain sensitive information by measuring the completion time of operations that verify (1) hashes or (2) passwords. CVE-2009-3250 The saveForwardAttachments procedure in the Compose Mail functionality in vtiger CRM 5.0.4 allows remote authenticated users to execute arbitrary code by composing an e-mail message with an attachment filename ending in Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 18       (1) .php in installations based on certain Apache HTTP Server configurations, (2) .php. on Windows, or (3) .php/ on Linux, and then making a direct request to a certain pathname under storage/. s. t CVE-2009-2412 Multiple integer overflows in the Apache Portable Runtime gh (APR) library and the Apache Portable Utility library (aka APR-util) 0.9.x and 1.3.x i lr allow remote attackers to cause a denial of service (application crash) or possibly execute ul arbitrary code via vectors that trigger crafted calls to the (1) allocator_alloc or (2) f apr_palloc function in memory/unix/apr_pools.c in APR; or crafted calls to the (3) ns apr_rmm_malloc, (4) apr_rmm_calloc, or (5) apr_rmm_realloc function in ai misc/apr_rmm.c in APR-util; leading to buffer overflows. NOTE: some of these details et are obtained from third party information. rr hoCVE-2009-1195 The Apache HTTP Server 2.2.11 and earlier 2.2 versions does not properly handle Options=IncludesNOEXEC in the AllowOverride directive, t Au which allows local users to gain privileges by configuring (1) Options Includes, (2) Options +Includes, or (3) Options +IncludesNOEXEC in a .htaccess file, and then e, ut inserting an exec element in a .shtml file. t i CVE-2008-7271 Multiple cross-site scripting (XSS) vulnerabilities in the t ns Help Contents web application (aka the Help Server) in Eclipse IDE, possibly 3.3.2, I allow remote attackers to inject arbitrary web script or HTML via (1) the searchWord NS parameter to help/advanced/searchView.jsp or (2) the workingSet parameter in an add action to help/advanced/workingSetManager.jsp, a different issue than CVE-2010-4647. SA CVE-2008-0455 Cross-site scripting (XSS) vulnerability in the 11 mod_negotiation module in the Apache HTTP Server 2.2.6 and earlier in the 2.2.x series, 20 2.0.61 and earlier in the 2.0.x series, and 1.3.39 and earlier in the 1.3.x series allows remote authenticated users to inject arbitrary web script or HTML by uploading a file © with a name containing XSS sequences and a file extension, which leads to injection within a (1) "406 Not Acceptable" or (2) "300 Multiple Choices" HTTP response when the extension is omitted in a request for the file. Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 19       7.1.2 IIS Vulnerabilities CVE-2010-3229 The Secure Channel (aka SChannel) security package in Microsoft Windows Vista SP1 and SP2, Windows Server 2008 Gold, SP2, and R2, and s. Windows 7, when IIS 7.x is used, does not properly process client certificates during SSL t gh and TLS handshakes, which allows remote attackers to cause a denial of service (LSASS i outage and reboot) via a crafted packet, aka "TLSv1 Denial of Service Vulnerability." lr ul CVE-2010-1886 Microsoft Windows XP SP2 and SP3, Windows Server f 2003 SP2, Windows Vista SP1 and SP2, Windows Server 2008 SP2 and R2, and ns Windows 7 allow local users to gain privileges by leveraging access to a process with ai NetworkService credentials, as demonstrated by TAPI Server, SQL Server, and IIS et processes, and related to the Windows Service Isolation feature. NOTE: the vendor states rr that privilege escalation from NetworkService to LocalSystem does not cross a "security ho boundary." t Au CVE-2010-0112 Multiple SQL injection vulnerabilities in the Administrative Interface in the IIS extension in Symantec IM Manager before 8.4.16 e, ut allow remote attackers to execute arbitrary SQL commands via (1) the rdReport t parameter to rdpageimlogic.aspx, related to the sGetDefinition function in rdServer.dll, i t and SQL statements contained within a certain report file; (2) unspecified parameters in a ns I DetailReportGroup (aka DetailReportGroup.lgx) action to rdpageimlogic.aspx; the (3) NS selclause, (4) whereTrendTimeClause, (5) TrendTypeForReport, (6) whereProtocolClause, or (7) groupClause parameter in a SummaryReportGroup (aka SA SummaryReportGroup.lgx) action to rdpageimlogic.aspx; the (8) loginTimeStamp, (9) dbo, (10) dateDiffParam, or (11) whereClause parameter in a LoggedInUsers (aka 11 LoggedInUSers.lgx) action to (a) rdpageimlogic.aspx or (b) rdPage.aspx; the (12) 20 selclause, (13) whereTrendTimeClause, (14) TrendTypeForReport, (15) © whereProtocolClause, or (16) groupClause parameter to rdpageimlogic.aspx; (17) the groupList parameter to IMAdminReportTrendFormRun.asp; or (18) the email parameter to IMAdminScheduleReport.asp. CVE-2006-5858 Adobe ColdFusion MX 7 through 7.0.2, and JRun 4, when run on Microsoft IIS, allows remote attackers to read arbitrary files, list directories, or Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 20       read source code via a double URL-encoded NULL byte in a ColdFusion filename, such as a CFM file. s. CVE-2010-1256 Unspecified vulnerability in Microsoft IIS 6.0, 7.0, and 7.5, t when Extended Protection for Authentication is enabled, allows remote authenticated gh users to execute arbitrary code via unknown vectors related to "token checking" that i lr trigger memory corruption, aka "IIS Authentication Memory Corruption Vulnerability." ul CVE-2010-0112 Multiple SQL injection vulnerabilities in the f ns Administrative Interface in the IIS extension in Symantec IM Manager before 8.4.16 ai allow remote attackers to execute arbitrary SQL commands via (1) the rdReport et parameter to rdpageimlogic.aspx, related to the sGetDefinition function in rdServer.dll, rr and SQL statements contained within a certain report file; (2) unspecified parameters in a DetailReportGroup (aka DetailReportGroup.lgx) action to rdpageimlogic.aspx; the (3) ho selclause, (4) whereTrendTimeClause, (5) TrendTypeForReport, (6) t Au whereProtocolClause, or (7) groupClause parameter in a SummaryReportGroup (aka SummaryReportGroup.lgx) action to rdpageimlogic.aspx; the (8) loginTimeStamp, (9) e, ut dbo, (10) dateDiffParam, or (11) whereClause parameter in a LoggedInUsers (aka t LoggedInUSers.lgx) action to (a) rdpageimlogic.aspx or (b) rdPage.aspx; the (12) i t selclause, (13) whereTrendTimeClause, (14) TrendTypeForReport, (15) ns I whereProtocolClause, or (16) groupClause parameter to rdpageimlogic.aspx; (17) the NS groupList parameter to IMAdminReportTrendFormRun.asp; or (18) the email parameter to IMAdminScheduleReport.asp. SA CVE-2009-4890 Multiple cross-site scripting (XSS) vulnerabilities in the 11 login application in vBook 4.2.17 allow remote attackers to inject arbitrary web script or HTML via the (1) title and (2) message parameters. 20 CVE-2009-4445 Microsoft Internet Information Services (IIS), when used in © conjunction with unspecified third-party upload applications, allows remote attackers to create empty files with arbitrary extensions via a filename containing an initial extension followed by a : (colon) and a safe extension, as demonstrated by an upload of a .asp:.jpg file that results in creation of an empty .asp file, related to support for the NTFS Alternate Data Streams (ADS) filename syntax. NOTE: it could be argued that this is a Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 21       vulnerability in the third-party product, not IIS, because the third-party product should be applying its extension restrictions to the portion of the filename before the colon. s. CVE-2009-4444 Microsoft Internet Information Services (IIS) 5.x and 6.x t uses only the portion of a filename before a ; (semicolon) character to determine the file gh extension, which allows remote attackers to bypass intended extension restrictions of i lr third-party upload applications via a filename with a (1) .asp, (2) .cer, or (3) .asa first ul extension, followed by a semicolon and a safe extension, as demonstrated by the use of f asp.dll to handle a .asp;.jpg file. ns ai et rr ho t Au e, t iut t ns I NS SA 11 20 © Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 22       7.2 Patching Statistics in real systems. The following table (Table 3) has been extracted from Wright and Tanveer (2011). s. Table 3. Patching Analysis of Audited Systems. t No. 95% Confidence Interval of Average Policy % Prior Reports gh Analyzed days between patching (Mean) Patch time (CI) noting patching Windows Server 1571 41.1, 122.4 (86.2) 55.5, 87.9 98.4% i Windows Client 13,951 22.8, 69.3 (48.1) 29.6, 49.4 96.6% lr Other Windows Applications 30,290 58.1, 181.8 (125.2) 68.1% NA 18.15% ul Internet Facing Routers 515 58.2, 164.1 (114.2) 58.1% NA 8.7% Internal Routers 1,323 129.3, 384.6 (267.8) 73.2 NA 3.99% f Internal Switches 452 139.9, 483.9 (341.2) 87.5 NA 1.2% Firewalls 1,562 21.5, 65.7 (45.4) 24.5, 108.2 70.7% ns ai Note that in a test of patching and security configurations of systems that native Windows applications and servers are patched far more than are the supporting devices or et the applications running on the server. rr ho t Au e, t iut t ns I NS SA 11 20 © Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 23       7.3 Attack Level Definitions These are the definitions associated with network and host based attacks. s. 7.3.1 Critical t gh Any systems compromise is a Critical attack. Critical events include: i lr • A system compromise is any attack that has gained unauthorised access ul (including altering of files on the respective system). f ns • Bypassing a firewall filter or other security controls (inc VLANS) when ai this is not permitted. et • Any DOS {Denial of Service} (including DDOS) attack that significantly rr impairs performance. ho t • Virus infections or Trojans that are not stopped and infect systems. Au 7.3.2 High Security Risk e, Attacks with the potential to effect or compromise a system. ut These are appropriate or targeted attacks. High level risks are those that concern t i t relevant attacks against relevant systems and security controls. These are issues that need ns to be addressed as soon as possible to stop them becoming a critical issue. Any high level I attack has the potential to become a critical event on a system if left unattended. NS 7.3.3 Medium Security Risk SA Skilled scans or attacks with the potential to affect the system if security controls (including patching) were not in place. These are targeted but filtered attacks. 11 20 A medium level attack is defined as one that is targeted towards the systems in place but is not likely to succeed due to other factors that are in place. An example of this © would be an attack against a patched web server. The attack may be listed as high if the system was unpatched, but is now unlikely to cause any noticeable effect. 7.3.4 Low Security Risk A low level attack is an attack with little or no likelihood of compromising a Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 24       system. These are often general probes and tools often run by unsophisticated attackers. An example of a low level attack would be an attacker running an IIS targeted s. attack tool against an Apache web server on Linux. The attack being directed towards a t Microsoft Web server running IIS is not likely to cause any noticeable issues on a Linux gh based system with Apache. There are exceptions to this, for example, if that version of i lr Apache was configured with FrontPage extensions, than this attack (if against Windows ul ASP extensions) could be relevant and may be thus classified as either High or Medium. f ns 7.3.5 Suspicious Activity ai Suspicious Activity covers all traffic and system behaviour that is not explainable et or does not conform to any reasonable expectation of an attack and is not capable of rr causing damage to the system. 7.3.6 ho t Modifiers The following events are modifiers and may affect the level of an attack as Au reported. e, ut High volume of attacks t If a high volume of a particular attack occurs, the severity level may be increased. i t ns An example of this is: I Attack Low volume High Volume NS SCAN XMAS Low Level Attack Medium Level Attack ICMP Source Quench Low Level Attack Medium Level Attack WEB-MISC Attempt Medium Level Attack High Level Attack SA to execute cmd In the examples above, the volume affects the level assigned to the attack as a 11 large number of packets consumes bandwidth and may affect performance. In the Web 20 example, a large volume of attacks from a single source may signify a new or unpatched vulnerability that the attacker is trying to exploit and thus needs to be investigated. © Skilled and/or unexpected attacks “ICMP Source Quench” is generally considered a Suspicious packet and not an attack. If these packets have been forged or it is suspected that a “trusted” host has been compromised to send these, the attack may be rated as either Low or even Medium. Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 25       An example of this would be if “ICMP redirect host” packets where being received from the ISP upstream router. s. 7.3.7 Definition matrix t The following table is a guide for determining levels of risk associated with an attack. gh Critical High Medium Low Suspicious i lr Denial of Current and Possible loss Service could No loss of ICMP or ul Service Attack continuing loss of service if be slightly service large traffic (DOS or of service action is not effected if the likely to amounts that f DDOS) taken attack was to occur are unlikely ns ensue to affect ai service Interactive Compromised et System level systems or rr compromise evidence of such an ho Unauthorized t attempt Compromised Suspicion of file access/ systems or or attempts Au modification evidence of to access to such an protected e, attempt files Blocked Packets that Evidence of Packets General Misc ut attacks as are bypassing packet targeted at a scans dropped t noted on the the installed shaping / specific packets i t Firewall firewall policy detailed service that ns spoofing in may be order to vulnerable I bypass from other NS firewall rules sites Attacks as System Targeted Detailed General noted on the vulnerable to attacks on an probes and Scans SA DMZ IDS this attack open service continuing hosts (esp. if scans against 11 recently specific patched) services 20 Virus or Systems Evidence of New virus or Virus or Worm attacks infected a virus or worm worm worm detected blocked on © passing the external Anti-virus anti-virus system server Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 26       7.4 Statistical Tests These are the statistical tests used in this analysis. s. two-sample t-test26 t gh The two-sample t-test is used in comparing two independent sample means (t-test) i lr with Homogeneity of Variance ul f This test is used to compare two sample means. The independent variable is ns nominal level data and the dependent variable is interval/ratio level. ai Analysis of Variance (Anova) et Analysis of variance is merely regression when the predictive variables are rr qualitative. Covariance analysis is regression with some qualitative predictive variables ho and some quantitative predictive variables (the latter are then called "covariates" or t Au "covariables"). e, The easiest way to understand analysis of variance is as a generalization of ut Student's t-test: it informs the user if the mean of a quantitative variable is the same in t several groups (Student's t-test is limited to the case of two groups) or, in other words, if i t a quantitative variables depends on a qualitative variable. ns I A more general way of understanding analysis of variance is as a test comparing NS two models: checking if a quantitative variable y depends on a qualitative variable x is equivalent to comparing the models y ~ x and y ~ 1 (if the two models are significantly SA different, the more complex one, y ~ x, brings more information, i.e., the quantitative 11 variable y depends on the qualitative variable x, i.e., the mean of y is not the same in the 20 groups defined by x). X ij to be the ith value of the kth group and define the following values, © If we take k = 1...K and N = ∑ nk and we assume that X ij is normally distributed and are independent for all values of i and j with the expected normal values for the mean of                                                                                                                 26       See  http://ccnmtl.columbia.edu/projects/qmss/the_ttest/twosample_ttest.html  for   detail.   Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 27       µk and the standard deviation of σ K , we can obtain the best unbiased linear estimate of µk and σ K . These are defined to be: s. t µk is estimated by: igh ∑X lr k X .k = i nk ul f σ K is estimated by: ns ai 2 ∑( X − X. ) k k et S 2k = i ( nk − 1) rr ho t The F test value (for the ANOVA F Test) is hence defined (Casella, 2002) as: ⎡ n ( kX − X )2 ⎤ Au k ∑k ⎢⎢ ( k − 1) ⎥⎥ ⎣ ⎦ e, F= 2 ⎡ ( X − X ) ⎤ ut ∑∑ ⎢ ik .k ⎥ i k ⎢ ( k − 1) ⎥ t ⎣ ⎦ i t ns In this calculation, it is generally assumed that the population variance is equal I (variance homeostasis or the homogeneity of variances). In this event, the value for NS X can be written in a simplified form as: SA ⎡ n X ⎤ X = ∑ ⎢ k .k ⎥ k ⎣ N ⎦ 11 This results in an F distribution with a central F variable with (K-1) and (N-K) 20 degrees of freedom. This is of course one of the main failings with the ANOVA F test. If © the sample variances differ, the simplified value of X will no longer hold as being valid. As a consequence, the requirement for a suitable test of variances is necessary to ensure that homogeneity of variances exists. Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 28       Tukey-Kramer HSD Tukey-Kramer HSD (Honestly Significant Difference) test, or the Tukey–Kramer s. method, is a single-step multiple comparison procedure and statistical test generally used t in conjunction with an ANOVA to find which means are significantly different from one gh another. The Tukey-Kramer HSD compares all possible pairs of means, and is based on a i lr studentized range distribution q. The resultant distribution is comparable to the ul distribution of t from the t-test. f ns Tukey’s test compares the means of every treatment to the means of every other ai treatment. Hence, the test can be seen to apply simultaneously to the set of all pairwise et comparisons rr . ho t This test identifies where the difference between two means is greater than the standard error would be expected to allow. The confidence coefficient for the set, when Au all sample sizes are equal, is exactly 1 − α. For unequal sample sizes, the confidence e, coefficient is greater than 1 − α. In other words, the Tukey method is conservative when ut there are unequal sample sizes. t i t What is p-value? ns I In a criminal trial, a suspect is assumed ‘innocent’ unless proven otherwise. In a NS statistical test, we commonly assume ‘no difference’ between two groups of data. The p- value is a number that is between 0 and 1, a value closer to 1 means there are ‘no SA difference’, a value closer to 0 means two groups of data are significantly different. 11 Usually, the p-value needs to be less than 0.01 to establish there is significant difference between two groups of data. This cut-off value is chosen completely arbitrarily, and 20 needs to be adjusted to 0.001 or less if higher stringency is required. Technically © speaking, p-value of greater than 0.01 means the ‘null hypothesis’ is true, otherwise the ‘alternative hypothesis’ is true. What is the alpha (α) value? We have talked about the p-value threshold above. For a p-value cut-off of less than 0.05, the alpha value is 0.95, or more commonly expressed as a percentage 95%. Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 29       This equation links α and p-value: p-value threshold = 1 - α s. By definition, the alpha value is the probability of incorrectly rejecting the null t hypothesis. igh lr 0   1   ul The  result  is   f likely  due  to   ns Region  in  which  p-­‐ p-­‐value  threshold    or   random  chance.   value  signifies   1  –  α     ai statistical   et significance   rr What is confidence interval? ho When you’re considering one group of data, the confidence interval defines a t Au range of values above and below the sample mean. A 95% confidence interval means that e, if we resample from the data, then it is expected that 95% of the data lies within the ut interval. A 99% confidence interval is always smaller than a 85% confidence interval. t i t 99%  confidence   ns intervale  similarly  but   I involves  the  group   variance  are  reduced.are   NS 95%   less  likely   to  cponfidence   roduce  a   interval   serences.statistical   SA significance.d   Your  sample   11 Sample  mean   20 The confidence interval is useful for the calculation of audit estimates within a © particular α level. We can use old data to calculate a 95% confidence interval for a particular field in the spreadsheet. If the mean value for this year’s data lies outside of the 95% confidence interval, then the result is statistically significant at p-value < 0.5. This also equals to a α value of 0.95. Since the value is different from previous year, this means this account may potentially have some problems that deserve to be further Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 30       scrutinized. Therefore, confidence interval, alpha value, and p-value are closely related to each other. s. What is correlation? t Correlation is a measure of how two sets of numbers move up or down together, gh and whether they have similar trends. One example of correlated data is the yearly i lr unemployment rate and GDP of a country. In contrast, the number of birds that flew into ul my backyard each day and the Dow Jones figures for the day is likely to be uncorrelated. f ns If the correlation value is 1, it means the data moves together up and down, if the ai correlation is -1, it means the data moves in separate ways. A correlation value of 0 et means there are no relationship between the two sets of numbers. rr ho 5. HPing t Au Hping is THE tool for probing networks and injecting packets. For Pen testing with the crafting of an exploit packet, or in protocol fuzzing, HPing is an extremely e, versatile packet crafting tool. ut You can download the latest version of hping source code from http://www.hping.org/ t i t To install it, you need to compile it for your system. First change the file ns "libpcap_stuff.c" by modifying the line: I NS #include Change this to: #include SA The process is a standard make from here: 11 #./configure 20 #make © #make install HPing Operation HPing will by default send TCP packets, with no options set, to port 0 of the target address continuously at one second intervals. The typical system response to this type of probe is an RST Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 31       packet, which indicates that a system is present. In addition to this default behavior, HPing offers the following command line options: Hping3 [options] [target] s. t Protocol specific: gh --udp: generate UDP packets. i • lr ul • --icmp: generate ICMP packets. f • --rawip: generate IP packets with no TCP or UDP components. ns TCP Options: ai et • --syn: sets the SYN flag of a TCP packet. rr • --fin: setis the FIN flag of a TCP packet. ho t • --rst: sets the RST flag of a TCP packet. --push: sets the PSH flag of a TCP packet. Au • --ack: sets the ACK flag of a TCP packet. e, • ut • --urg: sets the URG flag of a TCP packet. t i Network and port options: t ns • --rand-dest [IP-addr-net]: will send packets to random targets defined in I the supplied network address block. NS • --interface [int]: use the supplied interface for sending packets. SA • --spoof [IP-addr]: use the supplied ip address as the ‘spoofed’ source address. 11 • --rand-source: randomize the source address. 20 • --destport [port]: supplied port will be used as the destination port. © Adding + will increment the port by 1 for each received response, adding ++ will increment the port for each packet sent. • --scan [port range/list]: supplied port range or list will be scanned. Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 32       • --baseport [port]: the supplied port will be used as the source port, which will increment by 1 for each packet sent. There is no + or ++ functionality. If no baseport is set, it is randomly selected (>1024). s. t • --keep: use a fixed source port for all packets gh Speed options: i lr • --fast: send 10 packets per second (default is 1 packet per second). ul f • --faster: send 1,000,000 packets per second if possible ns • --flood: send packets as fast as possible ai --interval [N], [uN]: send on packet every N seconds or every uN et • microseconds rr ho t Miscellaneous options: Au • --count [N]: send N number of packets. e, • --beep: beep when a packet is received. ut • --file [filename]: use supplied file contents as payload. Requires –data t i t option. ns --data [N]: length of payload to be sent in bytes. I • NS The many different options which makes HPing a versatile tool for testing various aspects of systems or devices. Leveraging the random source address option (–rand-source), firewall rules SA can be tested for validity. The speed options can be used to test DoS mitigation, or detection sensitivity of IDS/IPS devices. 11 20 © Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s. A comparative study of attacks against Corporate IIS and Apache Web Servers 33       8 References Bednarski, Greg M. and Branson, Jake; Carnegie Mellon University; “Information s. Warfare: Understanding Network Threats through Honeypot Deployment”, March t gh 2004 i lr Broersma, Matthew; Techworld, “Linux servers safer than ever” Published 20th January ul 2005 by TechWorld f http://www.techworld.com/security/news/index.cfm?NewsID=2983 ns CERT, “CERT/CC Statistics 1988-2005”, 2005, http://www.cert.org/stats/cert_stats.html ai CVE, CVE Site http://cve.mitre.org/data/downloads/allcves.html et Honeynet Project & Research Alliance, “Know Your Enemy: Honeywall CDROM Roo”, rr 17th May 2005a, http://www.honeynet.org/papers/cdrom/roo/index.html ho Honeynet Project & Research Alliance, “Know your Enemy: Tracking Botnets - Using t honeynets to learn more about Bots”, 13th March 2005b, Au http://www.honeynet.org/papers/bots/ e, Honeynet Project & Research Alliance, “Know Your Enemy: Honeynets in Universities - ut Deploying a Honeynet at an Academic Institution”, 26th April 2004a, t i t http://www.honeynet.org/papers/edu/ ns Honeynet Project & Research Alliance, “Know your Enemy: Trend Analysis”, 17th I December 2004b, http://www.honeynet.org/papers/trends/life-linux.pdf NS Snort, Snort User Manual, www.snort.org/assets/166/snort_manual.pdf Symantec, “Symantec Internet Security Threat Report”, January 1 – June 30, 2004. SA The SANS Institute, “Survival Time History”, 2005, The Internet Storm Centre, 11 http://isc.sans.org/survivalhistory.php 20 Wright, Craig S. & Zia, Tanveer, "Compliance or Security, what cost? (Poster)", ACISP 2011, 16th Australasian Conference on Information Security and Privacy, Melb. © Au. Author  Name,  email@address       nst ©2011TheSANSI it ute Aut et horr ai nsf ull right s.