JavaScript
  Home arrow JavaScript arrow Page 4 - Using Mod_Security to Protect Your Server
Dev Articles Forums 
ADO.NET  
Apache  
ASP  
ASP.NET  
C#  
C++  
ColdFusion  
COM/COM+  
Delphi-Kylix  
Design Usability  
Development Cycles  
DHTML  
Embedded Tools  
Flash  
Graphic Design  
HTML  
IIS  
Interviews  
Java  
JavaScript  
MySQL  
Oracle  
Photoshop  
PHP  
Reviews  
Ruby-on-Rails  
SQL  
SQL Server  
Style Sheets  
VB.Net  
Visual Basic  
Web Authoring  
Web Services  
Web Standards  
XML  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
JAVASCRIPT

Using Mod_Security to Protect Your Server
By: O'Reilly Media
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 2
    2008-10-09

    Table of Contents:
  • Using Mod_Security to Protect Your Server
  • Actions
  • PHP
  • Application Server Hardening

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Using Mod_Security to Protect Your Server - Application Server Hardening


    (Page 4 of 4 )

    Like web servers, application servers are flexible in their configuration. This flexibility allows them to be integrated into diverse environments. However, in many cases the out-of-the-box installation will not be hardened for Internet usage. Steps need to be taken to configure these servers so that they are secure. The following are some hardening guidelines for application servers.

    Java and .NET

    The following are hardening recommendations for all next generation web application servers, but particularly for Java and .NET servers.

    Hardening guidelines

    1. Run all applications over SSL.
    2. Do no rely on client-side validation. Make input validation decisions on the server.
    3. Use the HttpOnly cookie option to help protect against cross-site scripting.
    4. Plan how authentication and access controls work before implementation.
    5. Employ role-base authorization checks for resources such as pages and directories.
    6. Divide the file structure of the site into public and restricted areas and provide proper authentication and access controls to restricted areas.
    7. Validate all input for type, length, and format. Employ positive validation and check for known acceptable data before filtering for bad data.
    8. Handle exceptions securely by not providing debug or infrastructure details as part of the exception.
    9. Use absolute URLs when sites contain secure and unsecure items.
    10. Ensure parameters used in SQL statements or data access codes are validated for length and type of data to help prevent SQL injection.
    11. Mark cookies as “secure.” Restrict authentication cookies by requiring the use of the secure cookie property.
    12. Ensure authentication cookies are not persisted or logged.
    13. Make sure cookies have unique path/name combinations.
    14. Personalization cookies are separate from authentication cookies.
    15. Require error-directives or error pages for all web applications.
    16. Strong password policies are implemented for authentication.
    17. Define a low session timeout (15 minutes).
    18. Avoid generic server resource mappings such as wildcards (/*.do).
    19. Protect resources by storing them under the WEB-INF directory and not allowing direct access to them.
    20. Do not store sensitive data (passwords, private data, and so on) in a web application root directory or other browsable location.

    For More Information

    Apache. “Apache HTTP Server Project.” http://httpd.apache.org/.

    CERT. “Creating a Computer Security Incident Response Team: A Process for Getting Started.” http://www.cert.org/csirts/Creating-A-CSIRT.html.

    Howtoforge. “Secure Your Apache with mod_security.” http://www.howtoforge.com/apache_mod_security.

    Microsoft. Technical Overview of Internet Information Services (IIS) 6.0. http:// download.microsoft.com/download/8/a/7/8a700c68-d1af-4c8d-b11e-5f974636a7dc/ IISOverview.doc (accessed Dec. 1, 2006).

     “Checklist: Securing Your Web Server.”, http://msdn2.microsoft.com/en-us/library/ aa302351.aspx. 

    Microsoft., “Checklist: Securing ASP.NET.”; available from: http://msdn2.microsoft.com/ en-us/library/ms178699.aspx. 

    O’Reilly ONLamp.com. LAMP: The Open Source Platform. http://www.onlamp.com.

    PHP. “Hypertext Preprocessor.” http://www.php.net/.

    Ristic, Ivan. Apache Security. California: O’Reilly Media, Inc., 2005.

    Security Focus. “Incident Response Tools For Unix, Part One: System Tools.” http:// www.securityfocus.com/infocus/1679.

    Ubuntu. “What Is Ubuntu?” http://www.ubuntu.com/.


    DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware.

       · This article is an excerpt from the book "Securing Ajax Applications: Ensuring the...
     

    Buy this book now. This article is excerpted from chapter four of Securing Ajax Applications: Ensuring the Safety of the Dynamic Web, written by Christopher Wells (O'Reilly, 2007; ISBN: 0596529317). Check it out today at your favorite bookstore. Buy this book now.

    JAVASCRIPT ARTICLES

    - Validating Digits and Dates with jQuery`s Va...
    - Validating Ranges, Emails, and URLs with jQu...
    - More Uses for the jQuery Tooltip Plug-in`s b...
    - Building Image-Based Tooltips with the jQuer...
    - Using the jQuery Tooltip Plug-in`s bodyHandl...
    - Using Rangelength, Min and Max with the Vali...
    - Using Minlength and Maxlength with the Valid...
    - Modifying Tooltip Coordinates with the jQuer...
    - Applying a Fade Out Effect with the jQuery T...
    - Tracking Mouse Movements with the jQuery Too...
    - Checking Online Forms with the Validator jQu...
    - Nested JavaScript Functions as Objects
    - The jQuery Tooltip Plug-in
    - Active Client Pages at the Server
    - ACP Tab Web Page







    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 2 Hosted by Hostway
    Stay green...Green IT