LINE Developer Meetup in Fukuoka #16 http://connpass.com/event/38413/
LINE Developer Meetup in Fukuoka #16 http://connpass.com/event/38413/
ãã®ãã¡ããå°ããã¡ãã¨æ¸ãã¾ãããã¨ããããæéããªãã®ã§çµè«ã ãæ¸ãã¨ãã¿ã¤ãã«ãå ¨ã¦ã§Electronã§ã¢ããªãæ¸ãå ´åã¯æ°åãã¨æ ¹æ§ã§XSSãçºçãããªãããã«ããªããã°ãªããªãã ããã¾ã§Webã¢ããªã±ã¼ã·ã§ã³ä¸ã§XSSãåå¨ããã¨ãã¦ããå½±é¿ç¯å²ã¯ãã®Webã¢ããªã±ã¼ã·ã§ã³ã®ä¸ã«çã¾ãã®ã§ãWebã¢ããªã±ã¼ã·ã§ã³ã®æä¾å´ãããã許容ããã®ã§ããã°XSSã®åå¨ã«ç®ãã¤ãããã¨ãã§ãããããããElectronã¢ããªã§DOM-based XSSãä¸ãæã§ãçºçããã¨ã(ãããã)確å®ã«ä»»æã³ã¼ãå®è¡ã¸ã¨ã¤ãªãããå©ç¨è ã®PCã®(ãã®ã¦ã¼ã¶ã¼æ¨©éã§ã®)å ¨æ©è½ãæ»æè ã«ãã£ã¦å©ç¨ã§ããã ãã®ãããElectronã§ã¢ããªã±ã¼ã·ã§ã³ãä½æããéçºè ã¯æ°åãã¨æ ¹æ§ã§XSSãå®å ¨ã«ã¤ã¶ããªããã°ãªããªãã nodeIntegration:falseãContent-Security-Pol
12. 調æ»æ¹æ³ ⶠURLã®#以éã«U+2028ã¨DOM based XSSãèµ·ãå¾ãæååãã¤ã㦠ã¾ãã â· å¤ãªã¨ã©ã¼ãã§ãªããã¿ã http://host/#[U+2028]'"><svg/onload=alert(1)> 13. ãã㨠Benesseã®ãµã¤ãã«ã¡ãã£æ®éã®DOM based XSSããã£ã https://web.archive.org/web/20130723155109/http://manabi.benes se.ne.jp/#"><svg/onload=alert(1)> function writeAccesskeyForm(){ var htm = ''; var ownURI = location.href; //ç¥ htm+= '<input type="hidden" name="backurl" value="' + ownURI + '"
2015/4/16(æ¨)ï¼ãã¼ã¸ã®ä¸çªä¸ã«è¿½è¨ãè¨è¿°ãã¾ããã ãã®æããªãã¨ããã£ã³ãã¨ããã»ãã¥ãªãã£ã®ã¤ãã³ãã«åå ããæãã¢ã¦ããããã大äºãã¨è¨ãããã®ãæãåºãã¾ããã ã§ããæ®éèªåã®è¦ã¤ããç¥èã¯å¾ç大äºã«æ±ãã¦ããããããã ã¨æãã¾ãã ããã§ä»åã¯ãããã£ãä½ãããã¼ããªããã®ãæ¨ã¦ãã¹ããæºãè¾¼ãã è²ããªXSSã®PoCãå°ãæ¸ãåºãã¦ã¾ã¨ãã¾ããã ä»ã¾ã§èªåã§è¦ã¤ãããã®ãæµ·å¤ã®Security Researcheréããåéãããã®ãããã¾ãã ãã¦ãä»åãªã¹ãã¢ããããPoCã®è¦æ¹ã§ããããã¤ãã®é ç®ãããã¾ãã ä¸çªä¸ã®ãææ³ãã¯ã¿ã¤ãã«ã¿ãããªãã®ã ã¨æã£ã¦ä¸ããã äºçªç®ã®ãPoCãã¯ã¹ã¯ãªãããå®è¡ããçºã®ã³ã¼ãã§ããæ®ã©ãã¢ã©ã¼ããåºãã ãã®ã¹ã¯ãªããã®çºå±éºãªã³ã¼ãã¯ç¡ãã¤ããã§ãããèªåã®ãã©ã¦ã¶ã§å®è¡ããéã¯èªå·±è²¬ä»»ã§ãé¡ããã¾ãããªã³ã¯ãã¯ãªã
ä¸ç¹å®ã®ã¦ã¼ã¶ã¼ãå ¥åããMarkdownããã©ã¦ã¶ä¸ã§JavaScriptã使ã£ã¦HTMLã«å¤æããã¨ããå ´é¢ã«ããã¦ã¯ãJavaScriptã§å¤æãã¦HTMLãçæããã¨ããå¦çã®é½åä¸ã©ããã¦ãDOM-based XSSã®çºçãèããªãããã«ã¯ãããªãããã¨ãã£ã¦ãMarkdownããã¼ã¹ãHTMLãçæããã¨ããå¦çãã¹ã¦ãXSSãåå¨ããªãããã«æ³¨æããªããèªåã§æ¸ãã®ã大å¤ã ããmarkedãmarkdown-jsãªã©ã®æ¢åã®å¤æç¨ã®JSãæã£ã¦ãã¦ãããããXSSããªããã確èªããã®ã¯çµæ§å¤§å¤ã ã£ããããã ãããã£ãå ´åã«ã¯ãMarkdownããçæãããHTMLãRickDOMãéããã¨ã§ãä¸ãä¸HTMLå ã«JavaScriptãå«ã¾ãã¦ããã¨ãã¦ãããããé¤å¤ãã許å¯ãããè¦ç´ ã許å¯ãããå±æ§ã ãã§æ§ç¯ãããå®å ¨ãªHTMLã«åæ§ç¯ãããã¨ãã§ãããããã«ããããã£ã¦çæ
ç¥ã£ã¦ããã°æããªããXMLHttpRequestã«ããXSSã¸ã®å¯¾å¿æ¹æ³ï¼HTML5æ代ã®ãæ°ããã»ãã¥ãªãã£ã»ã¨ãã±ãããï¼3ï¼ï¼1/2 ãã¼ã¸ï¼ é£è¼ç®æ¬¡ çããããã«ã¡ã¯ããããã¨ã¼ã¸ã§ã³ãã®ã¯ãããããããã§ããååã¯ãåä¸ãªãªã¸ã³ããªã·ã¼ãçªç ´ããæ»æã®ä»£è¡¨çäºä¾ã§ããXSSã«ã¤ãã¦ãç¹ã«DOM based XSSã¨å¼ã°ãããã®ã«ã¤ãã¦è§£èª¬ãã¾ãããä»åã¯ãã®ç¶ãã¨ãã¦ãXMLHttpRequestã«ããXSSã解説ãã¾ãã XHR Level 2ã«ãããªã¢ã¼ãããã®ã³ã¼ãæ¿å ¥ã«ããXSS å¾æ¥ãXMLHttpRequestï¼ä»¥ä¸ãXHRï¼ã¯ã表示ãã¦ããããã¥ã¡ã³ãã¨åããªãªã¸ã³ï¼ãªãªã¸ã³ã«ã¤ãã¦ã¯ç¬¬1åãåç §ï¼ã¨ããéä¿¡ã§ãã¾ããã§ããããç¾å¨ã®ä¸»è¦ãªãã©ã¦ã¶ã¼ã§ã¯XHR Level 2ã¨å¼ã°ããå®è£ ã«ããããªãªã¸ã³ãè¶ ãã¦éä¿¡ãããã¨ãå¯è½ã«ãªã£ã¦ãã¾ãã ããã¯ãJav
ãã«ãã¡ã¾ãã¨ããã® ãããããPHPã®æç§æ¸ããã®ãã³æ¹çããã¦ããããããPHPã®æç§æ¸ ãPHP5.5対å¿çãã¨ãã¦åºçããã¾ãããæ§çã¯mysqlé¢æ°ã使ã£ã¦SQLå¼ã³åºããã¦ãã¾ããããmysqlé¢æ°ãPHP5.5ã«ã¦éæ¨å¥¨ã¨ãªã£ãããã®ç·æ¥å¯¾å¦çãªå 容ã¨ãªã£ã¦ããããã§ããã¤ã¾ããå¾æ¥mysqlé¢æ°ãå¼ã³åºãã¦ããç®æãmysqliã®å¼ã³åºãã«å¤æ´ããã¨ããã®ãã主ãªå¤æ´ç¹ã®ããã§ããã以å¤ã¯ãã¾ãå¤æ´ç¹ã¯è¦ãããã¾ããã æ¢ã«ãAmazonã§ã¯ãç±çãªèªè ã®æ¹ããã®è©³ç´°ã®ã¬ãã¥ã¼ãå±ãã¦ãã¾ãã ç¥æ¬å¾¡éè¨ï¼ è¨ããã¨ç¥ããPHPããã°ã©ãã³ã°æ¸ç±ã®ãã³ã°ã»ã©ã¼ã 2010å¹´9æã«çºå£²ãããåä½ã®æ¹è¨çã PHPã®ãã¼ã¸ã§ã³ãææ°ã®5.5ã«å¯¾å¿ãå 容ã¯åä½ã¨æ®ã©åãã å°ãåã«åä½ãè³¼å ¥ããæ¹ãæ¬æ¸ãè³¼å ¥ããæ¹ãããã§ãããã ãä¸ç¥ã ããã«ãã¦ãã帯ã®ãï¼ä¸äººã«èªã¾ããå®
åç´ã§ã¯ãªããææ°ãã¯ãã¹ãµã¤ãã¹ã¯ãªããã£ã³ã°ãäºæ ï¼HTML5æ代ã®ãæ°ããã»ãã¥ãªãã£ã»ã¨ãã±ãããï¼2ï¼ï¼1/3 ãã¼ã¸ï¼ é£è¼ç®æ¬¡ çããããã«ã¡ã¯ããããã¨ã¼ã¸ã§ã³ãã®ã¯ãããããããã§ãã第1åç®ã¯ãWebã¢ããªã±ã¼ã·ã§ã³ã»ãã¥ãªãã£ã®å¢çæ¡ä»¶ã§ãããªãªã¸ã³ã¨ããæ¦å¿µã«ã¤ãã¦èª¬æãã¾ããã ç¾å¨ã®Webãã©ã¦ã¶ã¼ã§ã¯ãåä¸ãªãªã¸ã³ã®ãªã½ã¼ã¹ã¯åãä¿è·ç¯å²ã«ãããã®ã¨ãããªãªã¸ã³ãè¶ ããã¢ã¯ã»ã¹ã«ã¤ãã¦ã¯ãªã½ã¼ã¹ã®æä¾å ãæ示çã«è¨±å¯ããªãéãã¯ã¢ã¯ã»ã¹ã§ããªãã¨ããããåä¸ãªãªã¸ã³ããªã·ã¼ï¼Same-Origin Policyï¼ãã«å¾ã£ã¦ãªã½ã¼ã¹ãä¿è·ãã¦ãã¾ãã ãã®ä¿è·ç¯å²ã§ãããªãªã¸ã³ãè¶ ãããªã½ã¼ã¹ã«ã¢ã¯ã»ã¹ããæ»æã®ä»£è¡¨äºä¾ã§ããã¯ãã¹ãµã¤ãã¹ã¯ãªããã£ã³ã°ï¼XSSï¼ã«ã¤ãã¦ãä»åãããã³æ¬¡åã®2åã«åããHTML5ã«ããã¦ããé«åº¦åãããæ»æã¨ããã®å¯¾çã説æãã¾
4. å ¸åçãªXSSãµã³ãã«ã«å¯¾ãããç´ æ´ãªçåã ⢠ã¯ããã¼ã®å¤ãã¢ã©ã¼ãã§è¡¨ç¤ºããã¦ããç¹ã«å±éºæ§ã¯ãªãã ããªæ°ããã ⢠ã¯ããã¼ã®å¤ã¯ãã©ã¦ã¶ã®ã¢ããªã³ãªã©ã§ã表示ã§ãããã ⢠任æã®JavaScriptãå®è¡ãããã¨è¨ã£ã¦ãããã¼ã ãã¼ã¸ä½ ãã°ä»»æã®JavaScriptãæ¸ããããè¦ã人ã®ãã©ã¦ã¶ã§å®è¡ ããããã⦠Copyright © 2013 HASH Consulting Corp. 4 5. ããããã®çåï¼JavaScriptã¯å±éºã? ⢠å®ã¯ãJavaScriptã®å®è¡èªä½ã¯å±éºã§ã¯ãªã ⢠Webã¯ãæªç¥ã®ï¼ã²ãã£ã¨ããã¨æªæã®ãã?ï¼ãµã¤ãã訪åã ã¦ããæªããã¨ããèµ·ããªãããã«è¨è¨ããã¦ãã ⢠JavaScriptã®ããµã³ãããã¯ã¹ãã«ããä¿è· â JavaScriptãããã¼ã«ã«ãã¡ã¤ã«ã«ã¢ã¯ã»ã¹ã§ããªã â JavaScriptããã¯ãªãã
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}