SlideShare a Scribd company logo
Foiling JD:
Top 10 Ways to Stop Hackers
ANAND KUMAR MISHRA
Microsoft Corporation
Introduction
 Practice Defense in Depth
 A well-configured server will often resist
even newly found vulnerabilities
 Example – the NT 4.0 system set up for
Eweek’s first OpenHack contest would
have remained secure against most
new attacks found over the next year
10. Secure Your Email client
 Outlook
 Apply the Outlook Security Update
 Outlook Express
 Move OE to Restricted Sites Zone
 Disable Active Scripting and Java
 Don’t read e-mail on a web server!
9. Restrict Anonymous
 Set RestrictAnonymous=2
 This blocks detailed enumeration of users
and groups over a variety of protocols
 (setting included in HiSec* templates)
 Do not allow system with RA=2 to become
master browser
8. ACL System Executables
 Remove ability for users to execute
system commands (cmd.exe, tftp.exe,
etc.)
 C:winnt (and subdirectories)

Dir *.exe /s /b > outfile.txt

Cacl *.exe files as such:
 Admins: Full
 System: Full
7. ACL Directories
 Remove permissions for IUSR, IWAM,
and Everyone to Write and Execute
files in all directories
 Dump directory list to file
 Run cacls against each directory
 Identify each entry with Everyone perms

Read/Execute

Write
 Reset perms as follows:
7. ACL Directories
Inetpub
Everyone:(OI)(CI)F
Set to admins:F, everyone:R
------------------------------------------------------------------------------
Documents and SettingsAll UsersDRM
Everyone:(OI)(CI)F
Set to everyone:R
------------------------------------------------------------------------------
Documents and SettingsAll UsersApplication DataMicrosoftHTML Help
Everyone:F
Documents and SettingsAll UsersApplication DataMicrosoftHTML Help
Everyone:(OI)(CI)(IO)F
Set to everyone:R
------------------------------------------------------------------------------
Documents and SettingsAll UsersApplication DataMicrosoftCryptoRSAMachineKeys
Everyone:(special access:)
READ_CONTROL
SYNCHRONIZE
FILE_GENERIC_READ
FILE_GENERIC_WRITE
FILE_READ_DATA
FILE_WRITE_DATA
FILE_APPEND_DATA
FILE_READ_EA
FILE_WRITE_EA
FILE_READ_ATTRIBUTES
FILE_WRITE_ATTRIBUTES
Remove
FILE_GENERIC_WRITE
FILE_WRITE_DATA
------------------------------------------------------------------------------
7. ACL Directories
InetpubAdminScripts
Everyone:(OI)(CI)F
Inherited permissions from Inetpub
------------------------------------------------------------------------------
Inetpubmailroot
Everyone:(OI)(CI)F
InetpubmailrootBadmail
Everyone:(OI)(CI)F
InetpubmailrootDrop
Everyone:(OI)(CI)F
InetpubmailrootMailbox
Everyone:(OI)(CI)F
InetpubmailrootPickup
Everyone:(OI)(CI)F
InetpubmailrootQueue
Everyone:(OI)(CI)F
InetpubmailrootRoute
Everyone:(OI)(CI)F
InetpubmailrootSortTemp
Everyone:(OI)(CI)F
Inherited permissions from Inetpub
------------------------------------------------------------------------------
7. ACL Directories
WINNTTasks
Everyone:(OI)(CI)(special access:)
READ_CONTROL
SYNCHRONIZE
FILE_GENERIC_READ
FILE_GENERIC_WRITE
FILE_GENERIC_EXECUTE
FILE_READ_DATA
FILE_WRITE_DATA
FILE_APPEND_DATA
FILE_READ_EA
FILE_WRITE_EA
FILE_EXECUTE
FILE_READ_ATTRIBUTES
FILE_WRITE_ATTRIBUTES
WINNTsystem32Setup
Everyone:(OI)(CI)F
Set to admins:F, everyone:R
------------------------------------------------------------------------------
WINNTsystem32inetsrvData
Everyone:F
Set to everyone:R
------------------------------------------------------------------------------
WINNTsystem32MicrosoftCryptoRSAMachineKeys
Everyone:(special access:)
Set to everyone:R
6. Disable Services

Alerter

Computer Browser

Indexing Service

Messenger

Print spooler

Remote Registry

Distributed File System

Workstation

Server

Telnet

Smtp
5. Filter Ports
42 WINS Host Name Server
80 HTTP
88 Kerberos
135 MS RPC
139 NetBIOS Session Service
389 LDAP
443 SSL
445 CIFS-SMB
464 kpasswd
593 HTTP endpoint mapper
636 SSL-ldap
3268 MS Global Catalog
3269 MS Global Catalog
3372 (Local-host only connection)
3389 MS Terminal Server
xxxx IIS 5.0 HTML Mgmt
5. Filter Ports
 Apply IPSec Port Filters
 Block access to ALL ports but

80, 443, etc.
5. Filter Ports
5. Filter Ports
 Apply Port Filtering at the Router
 Block all non-essential ports in BOTH
directions
 Why should DMZ webserver be doing
NetBIOS, TFTP, or HTTP OUTBOUND to
other Internet Hosts?

It Shouldn’t. Block It.
4. Disable NetBIOS
 Foil Feinman
 Don’t allow malicious users to access
tcp 139 and tcp/udp 445
 Without this access – it will be much
tougher for hacker to enumerate details
about users and groups
4. Disable NetBIOS
 IPSec
 Create Blocker rules for tcp 139 and tcp/udp 445
 Unbind File and Printer Sharing for Microsoft
Networks
 Will stop 139 from responding to requests
 Advanced IP filtering
 Only allow required ports
 Unbind NetBIOS from WINS
4. Unbind F&P Sharing
Must select
Advanced –
Advanced
Settings
445 disappears,
139 appears, but
does not
respond
No Reboot
Required
4. Advanced IP Filtering
Reboot Required !!
Only specified
ports are
allowed
4. Advanced IP Filtering
Reboot Required !!
WARNING
Selecting IP
Protocols –
Permit Only ‘6’
(tcp) will ALSO
allow ICMP ‘1’ –
even though
this is not
explicitely
defined
4. Unbind NetBIOS from
WINS
139
disappears,
445 still
accepts
connections
No Reboot
Required
4. Disable NetBIOS
 Most Secure Option Is to Unbind File
and Printer Sharing from the specified
adapter
 Both 139 and 445 will be prohibited
4. Foiling Feinman
 Aside from Blocking User Enumeration
via NetBIOS
 You must secure enumeration via SNMP
and LDAP
 Block tcp 389 and udp 161
 DO NOT weaken perms on AD during AD
setup

Or, remove EVERYONE group from Pre-
Windows 2000 Compatability group
4. Foiling Feinman
3. Apply Security Templates
 Templates located in:
 Winntsecuritytemplates

Basicdc

Basicsv

Basicws

Compatws

Hisecdc

Hisecws

Ocfiless

Ocfilesw

Securedc

Securews

HISECWEB – download from microsoft.com/security
2. Follow IIS5 Checklist
 Summary:
 Remove sample apps

inetpubsamples

winnthelpiishelp

Program filescommon filessystemmsadc
 ACL IIS log file

Admin and system Full

Everyone RWC
 Enable IIS Logging
 Review all code on server for RevertToSelf calls
2. Follow IIS5 Checklist (cont)
 Disable File System Object

Regsrv32 scrrun.dll /u
 Remove IISADMPWD directory (if exists)

Only exists if upgraded from IIS4
 Remove script mappings

htr, idc, stm, shtm, shtml
 Disable Parent Paths

Scripts, msadc, etc.
Additional IIS Security Steps
 Remove or disable Admin web sites
 Remove Server extensions if you aren’t
using them (remove files, too)
 Run Permissions Wizard on all web
directories
 Disable Windows Auth on directories
that don’t need it
1. Apply Hotfixes
Search by Service Pack
1. Apply Hotfixes
 Apply the Patches
 MS00-086

Solves Directory Traversal Vulnerability

Supersedes 00-057 and 00-078
 MS01-007

Solves Win2K Privilege Escalation Vulnerability
 Visit microsoft.com/security for others…
1. Apply Hotfixes
DRAFT
Resources
 www.microsoft.com/security
 Bulletins and patches
 IIS5 Security Checklist
 HiSecWeb Template
 HFCheck (IIS5 hotfix checker)
 secure@microsoft.com
 Reports of security vulnerabilities in MS products
 secfdbck@microsoft.com
 Feedback on website, tools, checklists, etc.

More Related Content

PPTX
Recommended Software and Modifications for Server Security
PDF
OSDC 2018 | OPNsense: the “open” firewall for your datacenter by Thomas Niede...
PPTX
Server hardening
ODP
Hardening Database Server
PPTX
Cisco Ios Suneet
PDF
Windows server hardening 1
PPT
Ch08 Microsoft Operating System Vulnerabilities
PPT
Solaris servers sec
Recommended Software and Modifications for Server Security
OSDC 2018 | OPNsense: the “open” firewall for your datacenter by Thomas Niede...
Server hardening
Hardening Database Server
Cisco Ios Suneet
Windows server hardening 1
Ch08 Microsoft Operating System Vulnerabilities
Solaris servers sec

What's hot (20)

PDF
26.1.7 lab snort and firewall rules
PDF
Hardening Linux and introducing Securix Linux
PPTX
Whats New in OSSIM v2.3?
ODP
opensuse conference 2015: security processes and technologies for Tumbleweed
PDF
Incident response __threat_hunting
PPTX
Securing Hadoop with OSSEC
PDF
Network Security
PDF
McAfee Foundstone Update
PDF
Web Server Hardening
PPT
Linux Virus
TXT
Readme
PDF
Armitage – The Ultimate Attack Platform for Metasploit
PPT
Basics to Configure NW Device
PDF
Trusted extensions-gdansk-v1 0
PDF
Внедрение безопасности в веб-приложениях в среде выполнения
PDF
Null bhopal Sep 2016: What it Takes to Secure a Web Application
PPTX
System hardening - OS and Application
PDF
Snort296x centos6x 2
PPTX
Advanced OSSEC Training: Integration Strategies for Open Source Security
PPT
На страже ваших денег и данных
26.1.7 lab snort and firewall rules
Hardening Linux and introducing Securix Linux
Whats New in OSSIM v2.3?
opensuse conference 2015: security processes and technologies for Tumbleweed
Incident response __threat_hunting
Securing Hadoop with OSSEC
Network Security
McAfee Foundstone Update
Web Server Hardening
Linux Virus
Readme
Armitage – The Ultimate Attack Platform for Metasploit
Basics to Configure NW Device
Trusted extensions-gdansk-v1 0
Внедрение безопасности в веб-приложениях в среде выполнения
Null bhopal Sep 2016: What it Takes to Secure a Web Application
System hardening - OS and Application
Snort296x centos6x 2
Advanced OSSEC Training: Integration Strategies for Open Source Security
На страже ваших денег и данных

Similar to Technology to Stop Hackers (20)

PPTX
Getting Schooled DerbyCon 3.0
PPTX
Derby con 2014
PPT
Securing Windows web servers
PDF
The Infosec Revival
PDF
The Infosec Revival
PDF
rsa-usa-2019-keynote-paula-januszkiewicz
PDF
CSF18 - The Night is Dark and Full of Hackers - Sami Laiho
PDF
CSF18 - Moving from Reactive to Proactive Security - Sami Laiho
PDF
CNIT 123 Ch 8: OS Vulnerabilities
PDF
Tietoturvallisuuden_kevatseminaari_2013_Jarno_Niemela
PDF
CNIT 123 8: Desktop and Server OS Vulnerabilities
PPTX
Nightmares of a Penetration Tester ( How to protect your network)
DOCX
The license associated with the Belarc Advisor product allows
PPTX
Hunt for the red DA
PDF
Top 10 Ways To Make Hackers Excited: All About The Shortcuts Not Worth Taking
PDF
Tips to Remediate your Vulnerability Management Program
PPTX
Make Every Spin Count: Putting the Security Odds in Your Favor
PDF
CNIT 123: 8: Desktop and Server OS Vulnerabilites
PPT
Bh Win 03 Rileybollefer
PDF
Ch 8: Desktop and Server OS Vulnerabilites
Getting Schooled DerbyCon 3.0
Derby con 2014
Securing Windows web servers
The Infosec Revival
The Infosec Revival
rsa-usa-2019-keynote-paula-januszkiewicz
CSF18 - The Night is Dark and Full of Hackers - Sami Laiho
CSF18 - Moving from Reactive to Proactive Security - Sami Laiho
CNIT 123 Ch 8: OS Vulnerabilities
Tietoturvallisuuden_kevatseminaari_2013_Jarno_Niemela
CNIT 123 8: Desktop and Server OS Vulnerabilities
Nightmares of a Penetration Tester ( How to protect your network)
The license associated with the Belarc Advisor product allows
Hunt for the red DA
Top 10 Ways To Make Hackers Excited: All About The Shortcuts Not Worth Taking
Tips to Remediate your Vulnerability Management Program
Make Every Spin Count: Putting the Security Odds in Your Favor
CNIT 123: 8: Desktop and Server OS Vulnerabilites
Bh Win 03 Rileybollefer
Ch 8: Desktop and Server OS Vulnerabilites

More from Greater Noida Institute Of Technology (20)

PDF
Airline Analysis of Data Using Hadoop
PPTX
College Administration Management System
PPT
Virtual Private Network
PPTX
Sentimental Analysis of twitter data .
PPT
Hacking Question and Answer
PPT
Hacking and its Defence
PPTX
BroadBand Over powerline .
PPT
Modern Networking Hacking
PPT
Hack wireless internet connections or wifi
PPT
Hacking step (Methodology)
PPT
How to become Hackers .
Airline Analysis of Data Using Hadoop
College Administration Management System
Virtual Private Network
Sentimental Analysis of twitter data .
Hacking Question and Answer
Hacking and its Defence
BroadBand Over powerline .
Modern Networking Hacking
Hack wireless internet connections or wifi
Hacking step (Methodology)
How to become Hackers .

Recently uploaded (20)

PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PPTX
sap open course for s4hana steps from ECC to s4
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PPTX
Big Data Technologies - Introduction.pptx
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PPT
Teaching material agriculture food technology
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Encapsulation theory and applications.pdf
PDF
Electronic commerce courselecture one. Pdf
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPTX
Programs and apps: productivity, graphics, security and other tools
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PPTX
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
sap open course for s4hana steps from ECC to s4
Encapsulation_ Review paper, used for researhc scholars
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Big Data Technologies - Introduction.pptx
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Teaching material agriculture food technology
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Encapsulation theory and applications.pdf
Electronic commerce courselecture one. Pdf
“AI and Expert System Decision Support & Business Intelligence Systems”
Advanced methodologies resolving dimensionality complications for autism neur...
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Programs and apps: productivity, graphics, security and other tools
Digital-Transformation-Roadmap-for-Companies.pptx
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...

Technology to Stop Hackers

  • 1. Foiling JD: Top 10 Ways to Stop Hackers ANAND KUMAR MISHRA Microsoft Corporation
  • 2. Introduction  Practice Defense in Depth  A well-configured server will often resist even newly found vulnerabilities  Example – the NT 4.0 system set up for Eweek’s first OpenHack contest would have remained secure against most new attacks found over the next year
  • 3. 10. Secure Your Email client  Outlook  Apply the Outlook Security Update  Outlook Express  Move OE to Restricted Sites Zone  Disable Active Scripting and Java  Don’t read e-mail on a web server!
  • 4. 9. Restrict Anonymous  Set RestrictAnonymous=2  This blocks detailed enumeration of users and groups over a variety of protocols  (setting included in HiSec* templates)  Do not allow system with RA=2 to become master browser
  • 5. 8. ACL System Executables  Remove ability for users to execute system commands (cmd.exe, tftp.exe, etc.)  C:winnt (and subdirectories)  Dir *.exe /s /b > outfile.txt  Cacl *.exe files as such:  Admins: Full  System: Full
  • 6. 7. ACL Directories  Remove permissions for IUSR, IWAM, and Everyone to Write and Execute files in all directories  Dump directory list to file  Run cacls against each directory  Identify each entry with Everyone perms  Read/Execute  Write  Reset perms as follows:
  • 7. 7. ACL Directories Inetpub Everyone:(OI)(CI)F Set to admins:F, everyone:R ------------------------------------------------------------------------------ Documents and SettingsAll UsersDRM Everyone:(OI)(CI)F Set to everyone:R ------------------------------------------------------------------------------ Documents and SettingsAll UsersApplication DataMicrosoftHTML Help Everyone:F Documents and SettingsAll UsersApplication DataMicrosoftHTML Help Everyone:(OI)(CI)(IO)F Set to everyone:R ------------------------------------------------------------------------------ Documents and SettingsAll UsersApplication DataMicrosoftCryptoRSAMachineKeys Everyone:(special access:) READ_CONTROL SYNCHRONIZE FILE_GENERIC_READ FILE_GENERIC_WRITE FILE_READ_DATA FILE_WRITE_DATA FILE_APPEND_DATA FILE_READ_EA FILE_WRITE_EA FILE_READ_ATTRIBUTES FILE_WRITE_ATTRIBUTES Remove FILE_GENERIC_WRITE FILE_WRITE_DATA ------------------------------------------------------------------------------
  • 8. 7. ACL Directories InetpubAdminScripts Everyone:(OI)(CI)F Inherited permissions from Inetpub ------------------------------------------------------------------------------ Inetpubmailroot Everyone:(OI)(CI)F InetpubmailrootBadmail Everyone:(OI)(CI)F InetpubmailrootDrop Everyone:(OI)(CI)F InetpubmailrootMailbox Everyone:(OI)(CI)F InetpubmailrootPickup Everyone:(OI)(CI)F InetpubmailrootQueue Everyone:(OI)(CI)F InetpubmailrootRoute Everyone:(OI)(CI)F InetpubmailrootSortTemp Everyone:(OI)(CI)F Inherited permissions from Inetpub ------------------------------------------------------------------------------
  • 9. 7. ACL Directories WINNTTasks Everyone:(OI)(CI)(special access:) READ_CONTROL SYNCHRONIZE FILE_GENERIC_READ FILE_GENERIC_WRITE FILE_GENERIC_EXECUTE FILE_READ_DATA FILE_WRITE_DATA FILE_APPEND_DATA FILE_READ_EA FILE_WRITE_EA FILE_EXECUTE FILE_READ_ATTRIBUTES FILE_WRITE_ATTRIBUTES WINNTsystem32Setup Everyone:(OI)(CI)F Set to admins:F, everyone:R ------------------------------------------------------------------------------ WINNTsystem32inetsrvData Everyone:F Set to everyone:R ------------------------------------------------------------------------------ WINNTsystem32MicrosoftCryptoRSAMachineKeys Everyone:(special access:) Set to everyone:R
  • 10. 6. Disable Services  Alerter  Computer Browser  Indexing Service  Messenger  Print spooler  Remote Registry  Distributed File System  Workstation  Server  Telnet  Smtp
  • 11. 5. Filter Ports 42 WINS Host Name Server 80 HTTP 88 Kerberos 135 MS RPC 139 NetBIOS Session Service 389 LDAP 443 SSL 445 CIFS-SMB 464 kpasswd 593 HTTP endpoint mapper 636 SSL-ldap 3268 MS Global Catalog 3269 MS Global Catalog 3372 (Local-host only connection) 3389 MS Terminal Server xxxx IIS 5.0 HTML Mgmt
  • 12. 5. Filter Ports  Apply IPSec Port Filters  Block access to ALL ports but  80, 443, etc.
  • 14. 5. Filter Ports  Apply Port Filtering at the Router  Block all non-essential ports in BOTH directions  Why should DMZ webserver be doing NetBIOS, TFTP, or HTTP OUTBOUND to other Internet Hosts?  It Shouldn’t. Block It.
  • 15. 4. Disable NetBIOS  Foil Feinman  Don’t allow malicious users to access tcp 139 and tcp/udp 445  Without this access – it will be much tougher for hacker to enumerate details about users and groups
  • 16. 4. Disable NetBIOS  IPSec  Create Blocker rules for tcp 139 and tcp/udp 445  Unbind File and Printer Sharing for Microsoft Networks  Will stop 139 from responding to requests  Advanced IP filtering  Only allow required ports  Unbind NetBIOS from WINS
  • 17. 4. Unbind F&P Sharing Must select Advanced – Advanced Settings 445 disappears, 139 appears, but does not respond No Reboot Required
  • 18. 4. Advanced IP Filtering Reboot Required !! Only specified ports are allowed
  • 19. 4. Advanced IP Filtering Reboot Required !! WARNING Selecting IP Protocols – Permit Only ‘6’ (tcp) will ALSO allow ICMP ‘1’ – even though this is not explicitely defined
  • 20. 4. Unbind NetBIOS from WINS 139 disappears, 445 still accepts connections No Reboot Required
  • 21. 4. Disable NetBIOS  Most Secure Option Is to Unbind File and Printer Sharing from the specified adapter  Both 139 and 445 will be prohibited
  • 22. 4. Foiling Feinman  Aside from Blocking User Enumeration via NetBIOS  You must secure enumeration via SNMP and LDAP  Block tcp 389 and udp 161  DO NOT weaken perms on AD during AD setup  Or, remove EVERYONE group from Pre- Windows 2000 Compatability group
  • 24. 3. Apply Security Templates  Templates located in:  Winntsecuritytemplates  Basicdc  Basicsv  Basicws  Compatws  Hisecdc  Hisecws  Ocfiless  Ocfilesw  Securedc  Securews  HISECWEB – download from microsoft.com/security
  • 25. 2. Follow IIS5 Checklist  Summary:  Remove sample apps  inetpubsamples  winnthelpiishelp  Program filescommon filessystemmsadc  ACL IIS log file  Admin and system Full  Everyone RWC  Enable IIS Logging  Review all code on server for RevertToSelf calls
  • 26. 2. Follow IIS5 Checklist (cont)  Disable File System Object  Regsrv32 scrrun.dll /u  Remove IISADMPWD directory (if exists)  Only exists if upgraded from IIS4  Remove script mappings  htr, idc, stm, shtm, shtml  Disable Parent Paths  Scripts, msadc, etc.
  • 27. Additional IIS Security Steps  Remove or disable Admin web sites  Remove Server extensions if you aren’t using them (remove files, too)  Run Permissions Wizard on all web directories  Disable Windows Auth on directories that don’t need it
  • 28. 1. Apply Hotfixes Search by Service Pack
  • 29. 1. Apply Hotfixes  Apply the Patches  MS00-086  Solves Directory Traversal Vulnerability  Supersedes 00-057 and 00-078  MS01-007  Solves Win2K Privilege Escalation Vulnerability  Visit microsoft.com/security for others…
  • 31. Resources  www.microsoft.com/security  Bulletins and patches  IIS5 Security Checklist  HiSecWeb Template  HFCheck (IIS5 hotfix checker)  secure@microsoft.com  Reports of security vulnerabilities in MS products  secfdbck@microsoft.com  Feedback on website, tools, checklists, etc.