google hacking for cryptographic secrets

25
Outline Google Hacking Cryptographic Secrets Automatic Tools Countermeasures Google Code Search Conclusion Google Hacking for Cryptographic Secrets Emin ˙ Islam Tatlı [email protected] Department of Computer Science, University of Mannheim NEC Research-Heidelberg, 10 November 2006 Emin ˙ Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Upload: dr-emin-islam-tatli

Post on 17-May-2015

26.744 views

Category:

Documents


13 download

TRANSCRIPT

Page 1: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Google Hacking for Cryptographic Secrets

Emin Islam Tatlı[email protected]

Department of Computer Science, University of Mannheim

NEC Research-Heidelberg, 10 November 2006

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 2: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Outline

1 Google Hacking

2 Cryptographic Secrets

3 Automatic Tools

4 Countermeasures

5 Google Code Search

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 3: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

MotivationAdvanced Search ParametersExamples of Google Hacking

Motivation

Google has the index size over 20 billion entries

try to search -"fgkdfgjisdfgjsiod"

Hackers use google to search vulnerabilities

called Google Hackingvulnerable servers, files and applications, files containingusernames-passwords, sensitive directories, online devices, etc.Google Hacking Database [1] ⇒ 1468 entries in 14 groups (byOctober 2006)

What about Cryptographic Secrets?

In this talk, we find out cryptographic secrets with google

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 4: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

MotivationAdvanced Search ParametersExamples of Google Hacking

Advanced Search Parameters

[all]inurl

[all]intext

[all]intitle

site

ext, filetype

symbols: - . * |

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 5: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

MotivationAdvanced Search ParametersExamples of Google Hacking

Examples of Google Hacking I

Unauthenticated programs

"PHP Version" intitle:phpinfo inurl:info.php

Applications containing SQL injection & path modificationvulnerabilities

"advanced guestbook * powered" inurl:addentry.php

intitle:"View Img" inurl:viewimg.php

Security Scanner Reports

"Assessment Report" "nessus" filetype:pdf

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 6: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

MotivationAdvanced Search ParametersExamples of Google Hacking

Examples of Google Hacking II

Private data listings

"index of private|privat|ozel"

phone address email intitle:"Curriculum Vitae"

Database applications&error files

"Welcome to phpmyadmin ***" "running on * asroot@*" intitle:phpmyadmin

"mysql error with query"

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 7: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

MotivationAdvanced Search ParametersExamples of Google Hacking

Examples of Google Hacking III

Online Devices

inurl:"hp/device/this.LCDispatcher"

intitle:liveapplet inurl:LvAppl

"Please wait....." intitle:"SWW link"

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 8: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Hashed PasswordsSecret KeysPublic KeysPrivate KeysEncrypted MessagesSigned Messages

Cryptographic Secrets

1 Hashed Passwords

2 Secret Keys

3 Public Keys

4 Private Keys

5 Encrypted Messages

6 Signed Messages

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 9: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Hashed PasswordsSecret KeysPublic KeysPrivate KeysEncrypted MessagesSigned Messages

Hashed Passwords

Cleartext passwords

ext:log inurl:password

Hashed passwords in dump files

"create table" "insert into""pass|passwd|password" (ext:sql | ext:dump |ext:dmp)

intext:"password|pass|passwd"intext:"md5|sha1|crypt" (ext:sql | ext:dump |ext:dmp)

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 10: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Hashed PasswordsSecret KeysPublic KeysPrivate KeysEncrypted MessagesSigned Messages

Secret Keys

Secret keys in Kerberos

inurl:"kdc.conf" ext:conf

inurl:"slave datatrans" OR inurl:"from master"

Java keystores

keystore ext:ks

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 11: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Hashed PasswordsSecret KeysPublic KeysPrivate KeysEncrypted MessagesSigned Messages

Public Keys

PGP public keys

"BEGIN PGP PUBLIC KEY BLOCK" (ext:txt | ext:asc |ext:key)

Public keys in certificates

"Certificate:Data:Version" "BEGIN CERTIFICATE"(ext:crt | ext:asc | ext:txt)

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 12: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Hashed PasswordsSecret KeysPublic KeysPrivate KeysEncrypted MessagesSigned Messages

Private Keys

PGP private keys

"BEGIN (DSA|RSA)" ext:key

"BEGIN PGP PRIVATE KEY BLOCK" inurl:txt|asc

"index of" "secring.gpg"

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 13: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Hashed PasswordsSecret KeysPublic KeysPrivate KeysEncrypted MessagesSigned Messages

Encrypted Messages

PGP encrypted files

-"public|pubring|pubkey|signature|pgp|and|or|release" ext:gpg

More encrypted files

-intext:"and" (ext:enc | ext:axx)

XML encrypted elements

"ciphervalue" ext:xml

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 14: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Hashed PasswordsSecret KeysPublic KeysPrivate KeysEncrypted MessagesSigned Messages

Signed Messages

Signed emails

"BEGIN PGP SIGNED MESSAGE" "From" "Date""Subject" (ext:eml | ext:txt | ext:asc)

File signatures

-"and|or" "BEGIN PGP SIGNATURE" ext:asc

PGP signed messages

"BEGIN PGP SIGNED MESSAGE" -"From" (ext:txt |ext:asc | ext:xml)

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 15: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

GooscanSitediggerGoolinkAdvancedDorkGoogle Advanced Operations Toolbar

Automatic Tools

1 Gooscan

2 Sitedigger

3 Goolink

4 AdvancedDork

5 Google Advanced Operation Toolbar

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 16: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

GooscanSitediggerGoolinkAdvancedDorkGoogle Advanced Operations Toolbar

Gooscan [7]

a Unix/Linux script to check google hacking queries againstyour system

uses GHD [1]

to execute:$ gooscan -t www.google.de -q "BEGIN (DSA|RSA)ext:key" -s de -o output.html

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 17: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

GooscanSitediggerGoolinkAdvancedDorkGoogle Advanced Operations Toolbar

Sitedigger [6]

free from Foundstonecompany

supports both GHD andFoundstone’s own hackingdatabase

for a given host, all entries inthe database are queried

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 18: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

GooscanSitediggerGoolinkAdvancedDorkGoogle Advanced Operations Toolbar

Goolink [5]

Goolink queries Google for aparticular chosen search fromGHD

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 19: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

GooscanSitediggerGoolinkAdvancedDorkGoogle Advanced Operations Toolbar

AdvancedDork [2]

not specific to googlehacking

a Firefox extension for googlesearches

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 20: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

GooscanSitediggerGoolinkAdvancedDorkGoogle Advanced Operations Toolbar

Google Advanced Operations Toolbar [3]

a Firefox extensionprovides a shortcut of Google’s advanced search functions

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 21: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Security Countermeasures

1 Use automatic tools to check your system

2 Use Robot Exclusion Standart (robots.txt)

3 Install and manage Google Honeypot [4]

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 22: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Google Code Search

search keywords within source files(www.google.com/codesearch)

find application bugs (e.g. sql injection, xss injection, bufferoverflows, etc.) in the source files

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 23: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

Conclusion

Cryptography requires secrets to be kept secret

Google indexes your secrets and makes public

Take the required security countermeasures and protect yoursecrets

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 24: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

References I

Google Hacking Database. http://johnny.ihackstuff.com

AdvancedDork- A Firefox extension for google searches.http://johnny.ihackstuff.com

Google Advanced Operation Toolbar.https://addons.mozilla.org/firefox/1258/

Google Hack Honeypot Project. http://ghh.sourceforge.net

Goolink- Security Scanner.www.ghacks.net/2005/11/23/goolink-scanner-beta-preview/

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets

Page 25: Google Hacking for Cryptographic Secrets

OutlineGoogle Hacking

Cryptographic SecretsAutomatic ToolsCountermeasures

Google Code SearchConclusion

References II

SiteDigger v2.0 - Information Gathering Tool.http://www.foundstone.com

Gooscan - Google Security Scanner.http://johnny.ihackstuff.com

Emin Islam Tatlı (University of Mannheim) Google Hacking for Cryptographic Secrets