際際滷

際際滷Share a Scribd company logo
HTML Binary Hacks - GIF89a Polyglot - Cybozu Labs, Inc. TAKESAKO <takesako@shibuya.pm.prg>
I¨ll show you,  HTML 2.0 hacks.
1.0 HTML Browser Detection
HTML Quiz <img src=/slideshow/html-binary-hacks-gif89a-ployglot/429112/ ̄1.gif ̄ src= ̄2.gif ̄> (1) 1.gif  (2) 2.gif  (3) N/A Answers. Q1. What will you see?  (on your browser)
Q2. What¨s this? <img /src  = /slideshow/html-binary-hacks-gif89a-ployglot/429112/ ̄1.gif ̄  ̄ ̄ src{\x00} =  ̄2.gif ̄ ¨ src{\x0c} =  ̄3.gif ̄ src  =  ̄4.gif ̄ /> (1) 1.gif  (2) 2.gif (3) 3.gif (4) 4.gif Answers. ->   ie ->   Safari ->   firefox ->   others
?
print<<EOF; <img /src \x00 =&quot;ie.gif&quot; /''src \x00 =&quot;firefox1_5.gif&quot; /''src=/slideshow/html-binary-hacks-gif89a-ployglot/429112/&quot;firefox2_0.gif&quot; /&quot;&quot;src=&quot;gecko_others.gif&quot; &quot;s \x00 rc=&quot;safari2.gif&quot; &quot;src=&quot;safari3.gif&quot; &quot;&quot;src=&quot;konqueror.gif&quot; src \x00 =&quot;w3m.gif&quot; src \x0c =&quot;opera.gif&quot; src=&quot;others.gif&quot; src=&quot;lynx.gif&quot; /> EOF
http://wafful.org Demo
?
It can detect ^Konqueror ̄, ^Safari2 ̄ !
No JavaScript & No CSS hacks
lynx
w3m
Mozilla/5.0 (PLAYSTATION 3; 1.00) ?   others.gif
?
1.0 The End
2.0 GIF89a Polyglot
Animation GIF image  Yappoc.gif
どうても Yappo です 云輝にありがとう ございました┌鬘
Polyglot DEMO HTML/CSS & JS & Perl & GIF89a
JavaScript in GIF GIF89a( q /*....../);sub GIF89a{print &quot;Hello Perl!&quot;} __END__#*/ =1 );function GIF89a(){alert(&quot;Hello JavaScrpt!&quot;)} /*<body style=visibility:hidden> <div style=position:relative;visibility:visible> <h1>Hello HTML!</h1><!-- ................................................ ................................................ ................................................ ................................................ --><img src=/slideshow/html-binary-hacks-gif89a-ployglot/429112?> <script src=# language=JavaScript></script></div>  */ // ;
HTML/CSS in GIF GIF89a(q/*....../);sub GIF89a{print &quot;Hello Perl!&quot;} __END__#*/=1);function GIF89a(){alert(&quot;Hello JavaScrpt!&quot;)} /* <body style=visibility:hidden> <div style=position:relative;visibility:visible> <h1>Hello HTML!</h1> <!-- ................................................ ................................................ ................................................ ................................................ --> <img src=/slideshow/html-binary-hacks-gif89a-ployglot/429112?> <script src=# language=JavaScript></script> </div>  */// ;
Perl in GIF GIF89a(q /*....../ );sub GIF89a{print &quot;Hello Perl!&quot;} __END__ #*/=1);function GIF89a(){alert(&quot;Hello JavaScrpt!&quot;)} /*<body style=visibility:hidden> <div style=position:relative;visibility:visible> <h1>Hello HTML!</h1><!-- ................................................ ................................................ ................................................ ................................................ --><img src=/slideshow/html-binary-hacks-gif89a-ployglot/429112?> <script src=# language=JavaScript></script></div>  */// ;
Demo
?
?
Thank you

More Related Content

What's hot (20)

Income from other sources
Income from other sources Income from other sources
Income from other sources
IshitaSrivastava21
?
Agricultural income
Agricultural incomeAgricultural income
Agricultural income
vatsaj
?
As 15 vs ind as 19
As 15 vs ind as 19As 15 vs ind as 19
As 15 vs ind as 19
Archana CA
?
Partnership Act
Partnership ActPartnership Act
Partnership Act
ashutoshpratap
?
Tds
TdsTds
Tds
akash gupta
?
Aggregation of income, set off and carry forward
Aggregation of income, set off and carry forwardAggregation of income, set off and carry forward
Aggregation of income, set off and carry forward
CA Dr. Prithvi Ranjan Parhi
?
Indian Contract Act 1872
Indian Contract Act 1872Indian Contract Act 1872
Indian Contract Act 1872
Mayank Goel
?
Strike
StrikeStrike
Strike
kinnari raval
?
AGRICULTURAL INCOME.docx
AGRICULTURAL INCOME.docxAGRICULTURAL INCOME.docx
AGRICULTURAL INCOME.docx
Rajiv839406
?
Understanding Income Tax - Profits & Gains of Business or Profession [Sec 36 ...
Understanding Income Tax - Profits & Gains of Business or Profession [Sec 36 ...Understanding Income Tax - Profits & Gains of Business or Profession [Sec 36 ...
Understanding Income Tax - Profits & Gains of Business or Profession [Sec 36 ...
DVSResearchFoundatio
?
All About TDS Return Filing Online 2024.pptx
All About TDS Return Filing Online 2024.pptxAll About TDS Return Filing Online 2024.pptx
All About TDS Return Filing Online 2024.pptx
Legal Pillers
?
All about Advance Tax in India - With Calculation
All about Advance Tax in India - With CalculationAll about Advance Tax in India - With Calculation
All about Advance Tax in India - With Calculation
Rishi Menon
?
Gst Reconciliation
Gst ReconciliationGst Reconciliation
Gst Reconciliation
Admin SBS
?
Chapter vi a deductions
Chapter vi a deductionsChapter vi a deductions
Chapter vi a deductions
DVSResearchFoundatio
?
TDS
TDSTDS
TDS
Tabeer Yousuf
?
Formation, Deed, Registration OF PARTNERSHIP
Formation, Deed, Registration OF PARTNERSHIPFormation, Deed, Registration OF PARTNERSHIP
Formation, Deed, Registration OF PARTNERSHIP
SUBROTOACADEMICS
?
EXEMPTIONS OF CAPITAL GAIN
EXEMPTIONS OF CAPITAL GAINEXEMPTIONS OF CAPITAL GAIN
EXEMPTIONS OF CAPITAL GAIN
Md. Furqan Sabri
?
SEBI(LODR)Regulations - Obligations on listing of specified securities - Part II
SEBI(LODR)Regulations - Obligations on listing of specified securities - Part IISEBI(LODR)Regulations - Obligations on listing of specified securities - Part II
SEBI(LODR)Regulations - Obligations on listing of specified securities - Part II
DVSResearchFoundatio
?
Industrial relations ( A Case Of Pakistan)
Industrial relations ( A Case Of Pakistan)Industrial relations ( A Case Of Pakistan)
Industrial relations ( A Case Of Pakistan)
Aftab Alam
?
Articles of Association and its Alterations Simplified.
Articles of Association and its Alterations Simplified.Articles of Association and its Alterations Simplified.
Articles of Association and its Alterations Simplified.
Ankit Shah
?
Agricultural income
Agricultural incomeAgricultural income
Agricultural income
vatsaj
?
As 15 vs ind as 19
As 15 vs ind as 19As 15 vs ind as 19
As 15 vs ind as 19
Archana CA
?
Indian Contract Act 1872
Indian Contract Act 1872Indian Contract Act 1872
Indian Contract Act 1872
Mayank Goel
?
AGRICULTURAL INCOME.docx
AGRICULTURAL INCOME.docxAGRICULTURAL INCOME.docx
AGRICULTURAL INCOME.docx
Rajiv839406
?
Understanding Income Tax - Profits & Gains of Business or Profession [Sec 36 ...
Understanding Income Tax - Profits & Gains of Business or Profession [Sec 36 ...Understanding Income Tax - Profits & Gains of Business or Profession [Sec 36 ...
Understanding Income Tax - Profits & Gains of Business or Profession [Sec 36 ...
DVSResearchFoundatio
?
All About TDS Return Filing Online 2024.pptx
All About TDS Return Filing Online 2024.pptxAll About TDS Return Filing Online 2024.pptx
All About TDS Return Filing Online 2024.pptx
Legal Pillers
?
All about Advance Tax in India - With Calculation
All about Advance Tax in India - With CalculationAll about Advance Tax in India - With Calculation
All about Advance Tax in India - With Calculation
Rishi Menon
?
Gst Reconciliation
Gst ReconciliationGst Reconciliation
Gst Reconciliation
Admin SBS
?
Formation, Deed, Registration OF PARTNERSHIP
Formation, Deed, Registration OF PARTNERSHIPFormation, Deed, Registration OF PARTNERSHIP
Formation, Deed, Registration OF PARTNERSHIP
SUBROTOACADEMICS
?
SEBI(LODR)Regulations - Obligations on listing of specified securities - Part II
SEBI(LODR)Regulations - Obligations on listing of specified securities - Part IISEBI(LODR)Regulations - Obligations on listing of specified securities - Part II
SEBI(LODR)Regulations - Obligations on listing of specified securities - Part II
DVSResearchFoundatio
?
Industrial relations ( A Case Of Pakistan)
Industrial relations ( A Case Of Pakistan)Industrial relations ( A Case Of Pakistan)
Industrial relations ( A Case Of Pakistan)
Aftab Alam
?
Articles of Association and its Alterations Simplified.
Articles of Association and its Alterations Simplified.Articles of Association and its Alterations Simplified.
Articles of Association and its Alterations Simplified.
Ankit Shah
?

Viewers also liked (6)

HTML5 for Security Folks
HTML5 for Security FolksHTML5 for Security Folks
HTML5 for Security Folks
Vaibhav Gupta
?
Application Security Vulnerabilities: OWASP Top 10 -2007
Application Security Vulnerabilities: OWASP Top 10  -2007Application Security Vulnerabilities: OWASP Top 10  -2007
Application Security Vulnerabilities: OWASP Top 10 -2007
Vaibhav Gupta
?
OAuth 2.0 & Security Considerations
OAuth 2.0 & Security ConsiderationsOAuth 2.0 & Security Considerations
OAuth 2.0 & Security Considerations
Vaibhav Gupta
?
Application Security Risk Rating
Application Security Risk RatingApplication Security Risk Rating
Application Security Risk Rating
Vaibhav Gupta
?
Security Automation using ZAP
Security Automation using ZAPSecurity Automation using ZAP
Security Automation using ZAP
Vaibhav Gupta
?
Polyglot payloads in practice by avlidienbrunn at HackPra
Polyglot payloads in practice by avlidienbrunn at HackPraPolyglot payloads in practice by avlidienbrunn at HackPra
Polyglot payloads in practice by avlidienbrunn at HackPra
Mathias Karlsson
?
HTML5 for Security Folks
HTML5 for Security FolksHTML5 for Security Folks
HTML5 for Security Folks
Vaibhav Gupta
?
Application Security Vulnerabilities: OWASP Top 10 -2007
Application Security Vulnerabilities: OWASP Top 10  -2007Application Security Vulnerabilities: OWASP Top 10  -2007
Application Security Vulnerabilities: OWASP Top 10 -2007
Vaibhav Gupta
?
OAuth 2.0 & Security Considerations
OAuth 2.0 & Security ConsiderationsOAuth 2.0 & Security Considerations
OAuth 2.0 & Security Considerations
Vaibhav Gupta
?
Application Security Risk Rating
Application Security Risk RatingApplication Security Risk Rating
Application Security Risk Rating
Vaibhav Gupta
?
Security Automation using ZAP
Security Automation using ZAPSecurity Automation using ZAP
Security Automation using ZAP
Vaibhav Gupta
?
Polyglot payloads in practice by avlidienbrunn at HackPra
Polyglot payloads in practice by avlidienbrunn at HackPraPolyglot payloads in practice by avlidienbrunn at HackPra
Polyglot payloads in practice by avlidienbrunn at HackPra
Mathias Karlsson
?

More from takesako (19)

SECCON CTF セキュリティ室氏コンテスト_岸について
SECCON CTF セキュリティ室氏コンテスト_岸についてSECCON CTF セキュリティ室氏コンテスト_岸について
SECCON CTF セキュリティ室氏コンテスト_岸について
takesako
?
Acme minechan
Acme minechanAcme minechan
Acme minechan
takesako
?
Acme::MineChan LT demo
Acme::MineChan LT demoAcme::MineChan LT demo
Acme::MineChan LT demo
takesako
?
Node.js - JavaScript Thread Programming
Node.js - JavaScript Thread ProgrammingNode.js - JavaScript Thread Programming
Node.js - JavaScript Thread Programming
takesako
?
Node.js - sleep sort algorithm
Node.js - sleep sort algorithmNode.js - sleep sort algorithm
Node.js - sleep sort algorithm
takesako
?
x86x64 SSE4.2 POPCNT
x86x64 SSE4.2 POPCNTx86x64 SSE4.2 POPCNT
x86x64 SSE4.2 POPCNT
takesako
?
壅「議 屎ア蹶FJSON Validator
壅「議 屎ア蹶FJSON Validator壅「議 屎ア蹶FJSON Validator
壅「議 屎ア蹶FJSON Validator
takesako
?
屎号燕岌\もう匯つのバベルの満\直翫再匯
屎号燕岌\もう匯つのバベルの満\直翫再匯屎号燕岌\もう匯つのバベルの満\直翫再匯
屎号燕岌\もう匯つのバベルの満\直翫再匯
takesako
?
Perl6 Regex Programming with Rakudo
Perl6 Regex Programming with RakudoPerl6 Regex Programming with Rakudo
Perl6 Regex Programming with Rakudo
takesako
?
That Goes Without Alpha-Num (or Does It ?) all your base10 are belong to us
That Goes Without Alpha-Num (or Does It ?) all your base10 are belong to usThat Goes Without Alpha-Num (or Does It ?) all your base10 are belong to us
That Goes Without Alpha-Num (or Does It ?) all your base10 are belong to us
takesako
?
Devsumi2010 Ecmascript5 (ISO/IEC JTC1/SC22)
Devsumi2010 Ecmascript5 (ISO/IEC JTC1/SC22)Devsumi2010 Ecmascript5 (ISO/IEC JTC1/SC22)
Devsumi2010 Ecmascript5 (ISO/IEC JTC1/SC22)
takesako
?
Perl x86 JIT Programming
Perl x86 JIT ProgrammingPerl x86 JIT Programming
Perl x86 JIT Programming
takesako
?
YAPC::Asia 2008 Closing Ceremony
YAPC::Asia 2008 Closing CeremonyYAPC::Asia 2008 Closing Ceremony
YAPC::Asia 2008 Closing Ceremony
takesako
?
Devsumi2008 - YAPC::Asia 2008 Tokyo
Devsumi2008 - YAPC::Asia 2008 TokyoDevsumi2008 - YAPC::Asia 2008 Tokyo
Devsumi2008 - YAPC::Asia 2008 Tokyo
takesako
?
GIF89a Oldtype
GIF89a OldtypeGIF89a Oldtype
GIF89a Oldtype
takesako
?
Shibuyajs Digest
Shibuyajs DigestShibuyajs Digest
Shibuyajs Digest
takesako
?
HTML2.0 - digg - OSC2007-fall
HTML2.0 - digg - OSC2007-fallHTML2.0 - digg - OSC2007-fall
HTML2.0 - digg - OSC2007-fall
takesako
?
Shibuya.pm#8 - ImageFight - HTML 2.0 New Browser Detection
Shibuya.pm#8 - ImageFight - HTML 2.0 New Browser DetectionShibuya.pm#8 - ImageFight - HTML 2.0 New Browser Detection
Shibuya.pm#8 - ImageFight - HTML 2.0 New Browser Detection
takesako
?
Shibuyajs24 JavaScript.GIF x LiveConnect
Shibuyajs24 JavaScript.GIF x LiveConnectShibuyajs24 JavaScript.GIF x LiveConnect
Shibuyajs24 JavaScript.GIF x LiveConnect
takesako
?
SECCON CTF セキュリティ室氏コンテスト_岸について
SECCON CTF セキュリティ室氏コンテスト_岸についてSECCON CTF セキュリティ室氏コンテスト_岸について
SECCON CTF セキュリティ室氏コンテスト_岸について
takesako
?
Acme minechan
Acme minechanAcme minechan
Acme minechan
takesako
?
Acme::MineChan LT demo
Acme::MineChan LT demoAcme::MineChan LT demo
Acme::MineChan LT demo
takesako
?
Node.js - JavaScript Thread Programming
Node.js - JavaScript Thread ProgrammingNode.js - JavaScript Thread Programming
Node.js - JavaScript Thread Programming
takesako
?
Node.js - sleep sort algorithm
Node.js - sleep sort algorithmNode.js - sleep sort algorithm
Node.js - sleep sort algorithm
takesako
?
x86x64 SSE4.2 POPCNT
x86x64 SSE4.2 POPCNTx86x64 SSE4.2 POPCNT
x86x64 SSE4.2 POPCNT
takesako
?
壅「議 屎ア蹶FJSON Validator
壅「議 屎ア蹶FJSON Validator壅「議 屎ア蹶FJSON Validator
壅「議 屎ア蹶FJSON Validator
takesako
?
屎号燕岌\もう匯つのバベルの満\直翫再匯
屎号燕岌\もう匯つのバベルの満\直翫再匯屎号燕岌\もう匯つのバベルの満\直翫再匯
屎号燕岌\もう匯つのバベルの満\直翫再匯
takesako
?
Perl6 Regex Programming with Rakudo
Perl6 Regex Programming with RakudoPerl6 Regex Programming with Rakudo
Perl6 Regex Programming with Rakudo
takesako
?
That Goes Without Alpha-Num (or Does It ?) all your base10 are belong to us
That Goes Without Alpha-Num (or Does It ?) all your base10 are belong to usThat Goes Without Alpha-Num (or Does It ?) all your base10 are belong to us
That Goes Without Alpha-Num (or Does It ?) all your base10 are belong to us
takesako
?
Devsumi2010 Ecmascript5 (ISO/IEC JTC1/SC22)
Devsumi2010 Ecmascript5 (ISO/IEC JTC1/SC22)Devsumi2010 Ecmascript5 (ISO/IEC JTC1/SC22)
Devsumi2010 Ecmascript5 (ISO/IEC JTC1/SC22)
takesako
?
Perl x86 JIT Programming
Perl x86 JIT ProgrammingPerl x86 JIT Programming
Perl x86 JIT Programming
takesako
?
YAPC::Asia 2008 Closing Ceremony
YAPC::Asia 2008 Closing CeremonyYAPC::Asia 2008 Closing Ceremony
YAPC::Asia 2008 Closing Ceremony
takesako
?
Devsumi2008 - YAPC::Asia 2008 Tokyo
Devsumi2008 - YAPC::Asia 2008 TokyoDevsumi2008 - YAPC::Asia 2008 Tokyo
Devsumi2008 - YAPC::Asia 2008 Tokyo
takesako
?
GIF89a Oldtype
GIF89a OldtypeGIF89a Oldtype
GIF89a Oldtype
takesako
?
Shibuyajs Digest
Shibuyajs DigestShibuyajs Digest
Shibuyajs Digest
takesako
?
HTML2.0 - digg - OSC2007-fall
HTML2.0 - digg - OSC2007-fallHTML2.0 - digg - OSC2007-fall
HTML2.0 - digg - OSC2007-fall
takesako
?
Shibuya.pm#8 - ImageFight - HTML 2.0 New Browser Detection
Shibuya.pm#8 - ImageFight - HTML 2.0 New Browser DetectionShibuya.pm#8 - ImageFight - HTML 2.0 New Browser Detection
Shibuya.pm#8 - ImageFight - HTML 2.0 New Browser Detection
takesako
?
Shibuyajs24 JavaScript.GIF x LiveConnect
Shibuyajs24 JavaScript.GIF x LiveConnectShibuyajs24 JavaScript.GIF x LiveConnect
Shibuyajs24 JavaScript.GIF x LiveConnect
takesako
?

HTML Binary Hacks & GIF89a Ployglot

  • 1. HTML Binary Hacks - GIF89a Polyglot - Cybozu Labs, Inc. TAKESAKO <takesako@shibuya.pm.prg>
  • 2. I¨ll show you, HTML 2.0 hacks.
  • 3. 1.0 HTML Browser Detection
  • 4. HTML Quiz <img src=/slideshow/html-binary-hacks-gif89a-ployglot/429112/ ̄1.gif ̄ src= ̄2.gif ̄> (1) 1.gif (2) 2.gif (3) N/A Answers. Q1. What will you see? (on your browser)
  • 5. Q2. What¨s this? <img /src = /slideshow/html-binary-hacks-gif89a-ployglot/429112/ ̄1.gif ̄  ̄ ̄ src{\x00} =  ̄2.gif ̄ ¨ src{\x0c} =  ̄3.gif ̄ src =  ̄4.gif ̄ /> (1) 1.gif (2) 2.gif (3) 3.gif (4) 4.gif Answers. -> ie -> Safari -> firefox -> others
  • 6. ?
  • 7. print<<EOF; <img /src \x00 =&quot;ie.gif&quot; /''src \x00 =&quot;firefox1_5.gif&quot; /''src=/slideshow/html-binary-hacks-gif89a-ployglot/429112/&quot;firefox2_0.gif&quot; /&quot;&quot;src=&quot;gecko_others.gif&quot; &quot;s \x00 rc=&quot;safari2.gif&quot; &quot;src=&quot;safari3.gif&quot; &quot;&quot;src=&quot;konqueror.gif&quot; src \x00 =&quot;w3m.gif&quot; src \x0c =&quot;opera.gif&quot; src=&quot;others.gif&quot; src=&quot;lynx.gif&quot; /> EOF
  • 9. ?
  • 10. It can detect ^Konqueror ̄, ^Safari2 ̄ !
  • 11. No JavaScript & No CSS hacks
  • 12. lynx
  • 13. w3m
  • 14. Mozilla/5.0 (PLAYSTATION 3; 1.00) ? others.gif
  • 15. ?
  • 18. Animation GIF image Yappoc.gif
  • 19. どうても Yappo です 云輝にありがとう ございました┌鬘
  • 20. Polyglot DEMO HTML/CSS & JS & Perl & GIF89a
  • 21. JavaScript in GIF GIF89a( q /*....../);sub GIF89a{print &quot;Hello Perl!&quot;} __END__#*/ =1 );function GIF89a(){alert(&quot;Hello JavaScrpt!&quot;)} /*<body style=visibility:hidden> <div style=position:relative;visibility:visible> <h1>Hello HTML!</h1><!-- ................................................ ................................................ ................................................ ................................................ --><img src=/slideshow/html-binary-hacks-gif89a-ployglot/429112?> <script src=# language=JavaScript></script></div> */ // ;
  • 22. HTML/CSS in GIF GIF89a(q/*....../);sub GIF89a{print &quot;Hello Perl!&quot;} __END__#*/=1);function GIF89a(){alert(&quot;Hello JavaScrpt!&quot;)} /* <body style=visibility:hidden> <div style=position:relative;visibility:visible> <h1>Hello HTML!</h1> <!-- ................................................ ................................................ ................................................ ................................................ --> <img src=/slideshow/html-binary-hacks-gif89a-ployglot/429112?> <script src=# language=JavaScript></script> </div> */// ;
  • 23. Perl in GIF GIF89a(q /*....../ );sub GIF89a{print &quot;Hello Perl!&quot;} __END__ #*/=1);function GIF89a(){alert(&quot;Hello JavaScrpt!&quot;)} /*<body style=visibility:hidden> <div style=position:relative;visibility:visible> <h1>Hello HTML!</h1><!-- ................................................ ................................................ ................................................ ................................................ --><img src=/slideshow/html-binary-hacks-gif89a-ployglot/429112?> <script src=# language=JavaScript></script></div> */// ;
  • 24. Demo
  • 25. ?
  • 26. ?