SWLUG/μ›Ή ν•΄ν‚Ή

[Dreamhack/λ“œλ¦Όν•΅] xss-1

waterproof 2023. 11. 5. 19:08


 

 

[1] 문제 νŽ˜μ΄μ§€ 탐색

 

- vuln(xss) page

 

 

문제의 첫 화면이닀.

 

 

 

 

vuln(xss) page에 λ“€μ–΄κ°€λ³΄μ•˜λ‹€.

 

 

 

vuln νŽ˜μ΄μ§€μ— param κ°’μœΌλ‘œ <script>alert(1)</script>이 μ „λ‹¬λ˜μ–΄ "1"μ΄λΌλŠ” λ‚΄μš©μ˜ νŒμ—…μ°½μ΄ λœ¨λŠ” 것을 확인할 수 μžˆλ‹€.

 

 

 

μ†ŒμŠ€μ½”λ“œ λ˜ν•œ 특이점이 μ—†μ—ˆλ‹€.

 

 

 

- memo

 

 

memo νŽ˜μ΄μ§€μ— λ“€μ–΄κ°€λ³΄μ•˜λ‹€.

 

 

 

λ“€μ–΄κ°„ 횟수만큼 "hello"λΌλŠ” λ‚΄μš©μ˜ λ©”λͺ¨κ°€ λ‚˜νƒ€λ‚¬κ³ , url μ£Όμ†Œμ—μ„œλŠ” /memo νŽ˜μ΄μ§€μ— memo κ°’μœΌλ‘œ helloκ°€ μ „λ‹¬λ˜λŠ” 것을 확인할 수 μžˆλ‹€.

 

 

 

μ΄λ ‡κ²Œ memo νŒŒλΌλ―Έν„°μ— μž„μ˜μ˜ 값을 넣은 μ£Όμ†Œλ‘œ μ΄λ™ν•˜λ©΄ κ·Έ 값이 νŽ˜μ΄μ§€μ— 전달이 λ˜λŠ” 것을 λ³Ό 수 μžˆλ‹€.

 

 

 

이 νŽ˜μ΄μ§€μ˜ μ†ŒμŠ€μ½”λ“œλ₯Ό ν™•μΈν•΄λ³΄μ•˜λ‹€.

 

 

 

 

- flag

 

 

/flag νŽ˜μ΄μ§€λ₯Ό ν™•μΈν•΄λ³΄μ•˜λ‹€.

 

 

 

 

 

 

이 νŽ˜μ΄μ§€μ˜ μ†ŒμŠ€μ½”λ“œλ₯Ό ν™•μΈν•΄λ³΄μ•˜λ‹€.

 

 

 

 

 


[2] 문제 파일 탐색

 

 

λ‹€μš΄λ‘œλ“œ 받은 파일

 

 

 

 

 

 

app.py 파일의 λ‚΄μš©

 

1) 초기 μ„ μ–Έ λΆ€λΆ„

#!/usr/bin/python3
from flask import Flask, request, render_template
from selenium import webdriver
from selenium.webdriver.chrome.service import Service
import urllib
import os

app = Flask(__name__)
app.secret_key = os.urandom(32)

try:
    FLAG = open("./flag.txt", "r").read()
except:
    FLAG = "[**FLAG**]"

 

 

 

2) read_url ν•¨μˆ˜

 

def read_url(url, cookie={"name": "name", "value": "value"}):
    cookie.update({"domain": "127.0.0.1"})
    try:
        service = Service(executable_path="/chromedriver")
        options = webdriver.ChromeOptions()
        for _ in [
            "headless",
            "window-size=1920x1080",
            "disable-gpu",
            "no-sandbox",
            "disable-dev-shm-usage",
        ]:
            options.add_argument(_)
        driver = webdriver.Chrome(service=service, options=options)
        driver.implicitly_wait(3)
        driver.set_page_load_timeout(3)
        driver.get("http://127.0.0.1:8000/")
        driver.add_cookie(cookie)
        driver.get(url)
    except Exception as e:
        driver.quit()
        # return str(e)
        return False
    driver.quit()
    return True

 

 

 

3) check_xss ν•¨μˆ˜

 

def check_xss(param, cookie={"name": "name", "value": "value"}):
    #check_xssλŠ” read_urlν•¨μˆ˜ ν˜ΈμΆœν•˜μ—¬ vuln μ—”λ“œν¬μΈνŠΈ 접속
    url = f"http://127.0.0.1:8000/vuln?param={urllib.parse.quote(param)}"
    return read_url(url, cookie)

 

 

4) app.route("/")

 

#render_template : flaskμ—μ„œ μ œκ³΅ν•˜λŠ” ν•¨μˆ˜λ‘œ templates에 μ €μž₯된 html을 뢈러올 λ•Œ μ‚¬μš©ν•˜λŠ” ν•¨μˆ˜
@app.route("/")
def index():
    return render_template("index.html")

 

 

 

5) app.route("/vuln")

 

#μ‚¬μš©μžκ°€ μž…λ ₯ν•œ param 값을 좜λ ₯
#ν•„ν„° 없이 κ·ΈλŒ€λ‘œ μš”μ²­ 받은 λ‚΄μš©μ„ κ·ΈλŒ€λ‘œ 좜λ ₯
@app.route("/vuln")
def vuln():
    param = request.args.get("param", "")
    return param

 

 

 

6) app.route("/flag", methods=["GET", "POST"])

 

@app.route("/flag", methods=["GET", "POST"])
def flag():
    #μ΄μš©μžμ—κ²Œ URL을 μž…λ ₯λ°›λŠ” νŽ˜μ΄μ§€λ₯Ό 제곡
    if request.method == "GET":
        return render_template("flag.html")
    elif request.method == "POST":
        param = request.form.get("param")
        #νŒŒλΌλ―Έν„° κ°’κ³Ό 쿠킀에 FLAGλ₯Ό 포함해 check_xss ν•¨μˆ˜ 호좜
        if not check_xss(param, {"name": "flag", "value": FLAG.strip()}):
            return '<script>alert("wrong??");history.go(-1);</script>'

        return '<script>alert("good");history.go(-1);</script>'

 

 

 

7) app.route("/memo")

 

memo_text = ""

#μ‚¬μš©μžκ°€ μš”μ²­ν•œ λ‚΄μš©μ„ λ©”λͺ¨λ‘œ μž‘μ„±ν•˜μ—¬ 좜λ ₯
#μ—¬κΈ°λŠ” render_templateλ₯Ό 톡해 좜λ ₯ν•˜κΈ° λ•Œλ¬Έμ— μ·¨μ•½ν•˜μ§€ μ•ŠμŒ
@app.route("/memo")
def memo():
    global memo_text
    text = request.args.get("memo", "")
    memo_text += text + "\n"
    return render_template("memo.html", memo=memo_text)

 

 

8) μ„œλΉ„μŠ€ μ‹€ν–‰

 

app.run(host="0.0.0.0", port=8000)

 

 

 

 

templates 폴더 λ‚΄μ˜ html νŒŒμΌλ“€

 

 

 

 

1) base.html

 

<!doctype html>
<html>
  <head>
    <link rel="stylesheet" href="{{ url_for('static', filename='css/bootstrap.min.css') }}">
    <link rel="stylesheet" href="{{ url_for('static', filename='css/bootstrap-theme.min.css') }}">
    <link rel="stylesheet" href="{{ url_for('static', filename='css/non-responsive.css') }}">
    <title>{% block title %}{% endblock %} XSS-1</title>
    {% block head %}{% endblock %}
  </head>
<body>

    <!-- Fixed navbar -->
    <nav class="navbar navbar-default navbar-fixed-top">
      <div class="container">
        <div class="navbar-header">
          <a class="navbar-brand" href="/">XSS-1</a>
        </div>
        <div id="navbar">
          <ul class="nav navbar-nav">
            <li><a href="/">Home</a></li>
          </ul>

          <ul class="nav navbar-nav navbar-right">
          </ul>

        </div><!--/.nav-collapse -->
      </div>
    </nav>

    <div class="container">
      {% block content %}{% endblock %}
    </div> <!-- /container -->

    <!-- Bootstrap core JavaScript -->
    <script src="{{ url_for('static', filename='js/jquery.min.js')}}"></script>
    <script src="{{ url_for('static', filename='js/bootstrap.min.js') }}"></script> 
</body>
</html>

 

 

 

2) index.html

νŽ˜μ΄μ§€λ₯Ό λΆ„κΈ°ν•˜λŠ” μ†ŒμŠ€λ‘œ vul(xss) pageλ₯Ό ν΄λ¦­ν•˜μ˜€μ„λ•Œ μŠ€ν¬λ¦½νŠΈκ°€ μ‹€ν–‰λ˜μ–΄ alert(1) 창을 λ„μš΄λ‹€.

{% extends "base.html" %}
{% block title %}Index{% endblock %}

{% block head %}
  {{ super() }}
  <style type="text/css">
    .important { color: #336699; }
  </style>
{% endblock %}

{% block content %}
  <p class="important"><a href="/vuln?param=<script>alert(1)</script>">vuln(xss) page</a></p>
  <p class="important"><a href="/memo?memo=hello">memo</a></p>
  <p class="important"><a href="/flag">flag</a></p>
{% endblock %}

 

 

 

3) memo.html

 

{% extends "base.html" %}
{% block title %}Index{% endblock %}

{% block head %}
  {{ super() }}
  <style type="text/css">
    .important { color: #336699; }
  </style>
{% endblock %}

{% block content %}
  <pre>{{ memo }}</pre>
{% endblock %}

 

 

 

4) flag.html

νŒŒλΌλ―Έν„°λ₯Ό μž…λ ₯λ°›λŠ” νŽ˜μ΄μ§€μ΄λ‹€.

{% extends "base.html" %}
{% block title %}Index{% endblock %}

{% block head %}
  {{ super() }}
  <style type="text/css">
    .important { color: #336699; }
  </style>
{% endblock %}

{% block content %}
  <form method="POST">
    http://127.0.0.1:8000/vuln?param=<input type="text" name="param"/><br/>
    <input type="submit"/><br/>
  </form>
{% endblock %}

 

 

 


[3] 문제 풀이

 

β‘  vuln(xss) pageκ°€ 가진 취약점을 μ΄μš©ν•˜κΈ°

 

 

이 URL을 ν΄λ¦­ν•˜λ©΄ λΈŒλΌμš°μ €κ°€ ν•΄λ‹Ή URL을 μ—΄κ³ , 쿼리 λ§€κ°œλ³€μˆ˜μ˜ 값이 ν•΄μ„λœλ‹€.

λ”°λΌμ„œ <script>alert(1)</script>λΌλŠ” JavaScript μ½”λ“œκ°€ μ‚¬μš©μžμ˜ λΈŒλΌμš°μ €μ—μ„œ μ‹€ν–‰λœλ‹€.

이 경우, JavaScript μ½”λ“œλŠ” λ‹¨μˆœνžˆ κ²½κ³  창을 ν‘œμ‹œν•  λΏμ΄μ§€λ§Œ, μ•…μ˜μ μΈ κ³΅κ²©μžκ°€ 이λ₯Ό μ•…μš©ν•˜μ—¬ μ‚¬μš©μžμ˜ λΈŒλΌμš°μ €μ—μ„œ 더 μ‹¬κ°ν•œ μž‘μ—…μ„ μˆ˜ν–‰ν•  수 μžˆλ‹€. 예λ₯Ό λ“€μ–΄, μ‚¬μš©μžμ˜ μ„Έμ…˜ μΏ ν‚€λ₯Ό ν›”μΉ˜κ±°λ‚˜ λ‹€λ₯Έ μ•…μ˜μ μΈ λ™μž‘μ„ μˆ˜ν–‰ν•  수 μžˆλ‹€.

 

XSS 곡격은 μ‚¬μš©μžλ‘œλΆ€ν„° μž…λ ₯ λ°›λŠ” λΆ€λΆ„μ—μ„œ μ μ ˆν•œ μž…λ ₯ 검증과 μ΄μŠ€μΌ€μ΄ν”„ μ²˜λ¦¬κ°€ 이루어지지 μ•Šμ„ λ•Œ λ°œμƒν•œλ‹€. 이런 취약점이 μ‘΄μž¬ν•˜λ©΄ μ•…μ˜μ μΈ μŠ€ν¬λ¦½νŠΈκ°€ 싀행될 수 μžˆλ‹€. 

 

ν•΄λ‹Ή λ¬Έμ œμ—μ„œλŠ” λ³„λ„μ˜ 필터링이 μ‘΄μž¬ν•˜μ§€ μ•ŠλŠ” λ“―ν•˜λ©°, <script>, alert() λ“± νƒœκ·Έμ™€ κΈ°λŠ₯이 μ „λΆ€ μ •μƒμ μœΌλ‘œ μž‘λ™ν•˜κ³  μžˆλ‹€.

 

>> λ”°λΌμ„œ μœ„μ˜ νŽ˜μ΄μ§€λŠ” param νŒŒλΌλ―Έν„°λ‘œ xss 곡격이 κ°€λŠ₯ν•˜λ‹€.

 

 

 

 

β‘‘ flag νŽ˜μ΄μ§€ μž‘λ™ 방식

 

 

/flag에 μ ‘μ†ν•˜λ©΄ localhost의 /vuln νŽ˜μ΄μ§€λ‘œ param νŒŒλΌλ―Έν„°λ₯Ό 전솑할 수 μžˆλŠ” ꡬ성이닀.

 

 

 

 

이 μ½”λ“œλŠ” "/flag" κ²½λ‘œμ—μ„œ GET μš”청을 λ°›μœΌλ©΄ flagλ₯Ό λ³΄μ—¬μ£Όκ³ ,
POST μš”청을 λ°›μœΌλ©΄ check_xss ν•¨μˆ˜λ₯Ό ν˜ΈμΆœν•΄μ„œ "param" νΌ λ°μ΄ν„°λ₯Ό ν™•μΈν•˜μ—¬ XSS κ³΅κ²©μ„ κ²€μ‚¬ν•˜κ³  κ·Έμ— λ”°λ₯Έ μ‘닡을 λ°˜ν™˜ν•œλ‹€.

 

 

 

check_xss()λ₯Ό λ³΄λ©΄ 127.0.0.1:8000을 λŒ€μƒμœΌλ‘œ flagκ°€ ν¬ν•¨λœ μΏ ν‚€λ₯Ό read_url()의 μΈμžλ‘œ μ‹€ν–‰ν•œλ‹€.

 

 

 

 

 

1. cookie.update()둜 domain을 127.0.0.1둜 μ„€μ •ν•œλ‹€.

2. chromedriverλ₯Ό μ‹€ν–‰ν•˜κ³  127.0.0.1:8000λ₯Ό μ˜€ν”ˆν•œλ‹€.

3. 인자둜 받은 μΏ ν‚€λ₯Ό chromedriver 쿠킀에 μΆ”κ°€ν•œλ‹€.

4. 127.0.0.1:8000/vuln?param=[μž…λ ₯κ°’]으둜 쿠킀와 ν•¨κ»˜ μš”μ²­μ„ μ „μ†‘ν•œλ‹€.

 

 

μ‹œλ‚˜λ¦¬μ˜€λ₯Ό μ„€λͺ…ν•˜λ©΄,

chromedriver에 μ €μž₯된 flagλŠ” κ³΅κ²©λŒ€μƒμ˜ μ„Έμ…˜μ΄κ³  XSS둜 μ„Έμ…˜(μΏ ν‚€)을 νƒˆμ·¨ν•œλ‹€.

 
flagλ₯Ό μ–»λŠ” κ²ƒμ΄ λͺ©ν‘œμ΄λ―€λ‘œ 127.0.0.1:8000/vulnλ₯Ό μ΄μš©ν•΄μ„œ κ³΅κ²©λŒ€μƒ ν΄λΌμ΄μ–ΈνŠΈμ—μ„œ μ•…μ„± μŠ€ν¬λ¦½νŠΈκ°€ μ‹€ν–‰λ˜λ„둝 XSS payloadλ₯Ό μ „μ†‘ν•΄μ•Όν•œλ‹€.

 

 

 

β‘’ memo νŽ˜μ΄μ§€ μž‘λ™ 방식

 

 

 

이 μ½”λ“œλŠ” κ°„λ‹¨ν•œ λ©”λͺ¨μž₯을 κ΅¬ν˜„ν–ˆλ‹€.

 

 

text = request.args.get("memo", ""): μ‚¬μš©μžλŠ” "/memo" 경둜둜 μ ‘μ†ν•˜μ—¬ URLμ—μ„œ "memo"λΌλŠ” 인자λ₯Ό λ°›μ•„μ˜¨λ‹€.

예λ₯Ό λ“€μ–΄, "/memo?memo=λ‹΅μ΄λŒ€μ²΄λ­μ•Ό"κ³Ό 같이 μš”μ²­μ΄ 였면 "λ‹΅μ΄λŒ€μ²΄λ­μ•Ό"λ₯Ό κ°€μ Έμ˜¨λ‹€. (λ§Œμ•½ "memo" μΈμžκ°€ μ—†λ‹€λ©΄ 빈 λ¬Έμžμ—΄("")을 κΈ°λ³Έκ°’μœΌλ‘œ μ‚¬μš©ν•œλ‹€.)

 

memo_text += text + "\n": κ°€μ Έμ˜¨ ν…μŠ€νŠΈλ₯Ό μ „μ—­ λ³€μˆ˜μΈ memo_text에 μΆ”κ°€ν•œλ‹€. μ΄λ•Œ 각각의 λ©”λͺ¨λŠ” μƒˆ μ€„λ‘œ κ΅¬λΆ„λœλ‹€.

 

return render_template("memo.html", memo=memo_text): "memo.html" ν…œν”Œλ¦Ώμ„ λ Œλ”λ§ν•˜κ³ , ν˜„μž¬κΉŒμ§€μ˜ λ©”λͺ¨λ₯Ό ν•¨κ»˜ μ „λ‹¬ν•œλ‹€. 이λ₯Ό 톡해 μ‚¬μš©μžλŠ” ν™”λ©΄μ—μ„œ λ©”λͺ¨λ₯Ό 확인할 수 μžˆλ‹€.

 

 

>> μ‚¬μš©μžλŠ” "/memo" 경둜둜 μ ‘μ†ν•˜μ—¬ ν…μŠ€νŠΈλ₯Ό μž…λ ₯ν•˜κ³ , 이전에 μž…λ ₯ν•œ λ©”λͺ¨λ“€μ„ 확인할 수 μžˆλ‹€.

 

 

 

μš”μ•½

1. /vuln
:param νŒŒλΌλ―Έν„°μ—μ„œ XSS 취약점 λ°œμƒ

2. /memo
:memo νŒŒλΌλ―Έν„°λ‘œ νŽ˜μ΄μ§€μ— 데이터 μ €μž₯ κ°€λŠ₯

3. /flag
:check_xss(url,cookie) → read_url(url, cookie) → flagλ₯Ό 쿠킀에 μ €μž₯ → 127.0.0.1:8000/vuln?param=[μž…λ ₯κ°’]λ₯Ό 곡격 λŒ€μƒ 봇이 μš”μ²­

 

 

/memoλŠ” μš”μ²­ μ‹œ νŒŒλΌλ―Έν„°λ₯Ό ν†΅ν•΄μ„œ νŠΉμ • κ°’을 μ €μž₯ν•  μˆ˜ μžˆλŠ” κΈ°λŠ₯을 μˆ˜ν–‰ν•œλ‹€.

κ·Έλ ‡λ‹€λ©΄, bot이 127.0.0.1:8000/memo?memo=[μΏ ν‚€] μ™€ κ°™μ΄ μš”μ²­ν•˜λ„λ‘ XSS payloadλ₯Ό μ „μ†‘ν•˜λ©΄, /memo에 μΏ ν‚€μ— λ‹΄κΈ΄ flagκ°€ μ €μž₯될 κ²ƒμ΄λ‹€.

 

 

 

곡격 μˆœμ„œλ₯Ό μ •λ¦¬ν•˜λ©΄

 

1. /flagλ₯Ό 톡해 XSS νŽ˜μ΄λ‘œλ“œ 전솑

2. bot이 /vuln 을 톡해 μ „μ†‘ν•œ XSS νŽ˜μ΄λ‘œλ“œλ₯Ό μ‹€ν–‰

3. /memo 에 bot의 cookieκ°€ μ €μž₯

 

 

 

 

XSSμ—μ„œ μ‚¬μš©λ˜λŠ” λ„€ 가지 μ’…λ₯˜μ˜ 문법:

 

<script>

alert("hello"); <!-- λ©”μ‹œμ§€ 좜λ ₯ -->

document.cookie; <!-- μΏ ν‚€κ°’ -->

location.href=""; <!-- ""λ‚΄μ˜ 링크둜 μœ„μΉ˜ 이동 -->

document.location=""; <!-- "" 링크둜 이동 -->

</script>

 

 

 

 

μΏ ν‚€λ₯Ό νƒˆμ·¨ν•˜κΈ° μœ„ν•œ XSS payload

 

 

μœ„μ˜ 문법 쀑 쿠킀값을 좜λ ₯ν•˜λŠ” document.cookie와 location.hrefλ₯Ό 톡해 memoμ—μ„œ μΏ ν‚€λ₯Ό 좜λ ₯ν•˜λ„λ‘ μ½”λ“œλ₯Ό μ§œλ³΄κ² λ‹€.

 

<script>location.href='http://127.0.0.1:8000/memo?memo='+document.cookie</script>

 

μœ„μ˜ μ½”λ“œλ₯Ό /flag νŽ˜μ΄μ§€μ— μž…λ ₯ν•˜κ³  μ œμΆœν•˜λ©΄

vuln νŽ˜μ΄μ§€λ₯Ό 거쳐 memo νŽ˜μ΄μ§€μ— document.cookieκ°€ μ €μž₯될 것이닀.

 

 

 

 

 

 

μ •λ‹΅!!

 

 

 


[4] λŒ€μ‘ λ°©μ•ˆ

 

 

(1) μž…λ ₯κ°’ 검증 및 길이 μ œν•œ

 

whitelist λ˜λŠ” blacklist λ°©μ‹μœΌλ‘œ <script>같은 슀크립트 νƒœκ·Έλ“€μ— λŒ€ν•œ λ¬Έμžμ—΄ 검증을 μˆ˜ν–‰ν•œλ‹€.

(이 λ¬Έμ œμ—μ„œλŠ” λ¬Έμžμ—΄ 검증을 μˆ˜ν–‰ν•˜μ§€ μ•ŠλŠ”λ‹€.)

 

 

(2) HTML Entity μ‚¬μš©

 

 

XSSκ°€ λ°œμƒν•˜μ§€μ•Šλ„λ‘ HTML νƒœκ·Έλ“€μ„ 특수문자둜 ν‘œν˜„ν•˜λ„λ‘ HTML Entityλ₯Ό μ‚¬μš©ν•œλ‹€.

HTML Entityλ₯Ό μ‚¬μš©ν•˜λ©΄, κ³΅κ²©μžκ°€ <script>λ₯Ό μž…λ ₯ν•˜λ”λΌλ„ 좜λ ₯은 &lt;script&gt;둜 되기 λ•Œλ¬Έμ— XSSκ°€ λ°œμƒν•˜μ§€ μ•ŠλŠ”λ‹€.

 

 

(3) HttpOnly ν”Œλž˜κ·Έ μ„€μ •

 

λΈŒλΌμš°μ €μ—μ„œ 쿠킀에 μ ‘κ·Όν•  수 없도둝 HttpOnly ν”Œλž˜κ·Έλ₯Ό μ„€μ •ν•œλ‹€.

λ§Œμ•½, XSSκ°€ λ°œμƒν•˜λ”λΌλ„ λΈŒλΌμš°μ €κ°€ 쿠킀에 μ ‘κ·Όν•  수 μ—†κΈ° λ•Œλ¬Έμ— κ³΅κ²©μžλŠ” μΏ ν‚€λ₯Ό νƒˆμ·¨ν•  수 μ—†λ‹€.

 

 

 

 

 


[5] μ°Έκ³ 

 

https://keyme2003.tistory.com/entry/dreamhack-xss-1

 

[dreamhack] xss-1

κ°œλ…μ •λ¦¬ β—‹ XSS 크둜슀 μ‚¬μ΄νŠΈ μŠ€ν¬λ¦½νŒ…(Cross Site Scripting, XSS)은 κ³΅κ²©μžκ°€ κ³΅κ²©λŒ€μƒμ˜ λΈŒλΌμš°μ €μ—μ„œ μŠ€ν¬λ¦½νŠΈκ°€ μ‹€ν–‰λ˜λ„λ‘ μœ λ„ν•˜μ—¬ μ‚¬μš©μžμ˜ μ„Έμ…˜μ„ κ°€λ‘œμ±„κ±°λ‚˜, μ›Ήμ‚¬μ΄νŠΈλ₯Ό λ³€μ‘° λ˜λŠ” μ•…μ˜μ 

keyme2003.tistory.com

 

https://hobbylists.tistory.com/entry/XSSCross-Site-Scripting%EA%B3%B5%EA%B2%A9-%EC%8B%A4%EC%8A%B5-Dreamhack-%EC%8B%A4%EC%8A%B5%EC%98%88%EC%A0%9C

 

[XSS] XSS(Cross Site Scripting)곡격 μ‹€μŠ΅ - (Dreamhack μ‹€μŠ΅μ˜ˆμ œ)

XSS(CrossSiteScripting) μ„œλ²„μ˜ 응닡에 κ³΅κ²©μžκ°€ μ‚½μž…λœ μ•…μ„± 슀크립트λ₯Ό 받은 μ‚¬μš©μžμ˜ μ›Ή λΈŒλΌμš°μ €μ—μ„œ μ•…μ„± μŠ€ν¬λ¦½νŠΈκ°€ μ‹€ν–‰λ˜λŠ” 곡격 XSS 곡격을 μˆ˜ν–‰ν•˜κΈ° μœ„ν•΄ μš”κ΅¬λ˜λŠ” 쑰건 μ•…μ„± scriptκ°€ μ‚½μž…λ 

hobbylists.tistory.com

 

 

https://goldsony.tistory.com/m/259

 

[μ›Ή ν•΄ν‚Ή] Dreamhack xss-1(Level 1)

#259 1. κ°œμš” μ›Œκ²Œμž„ λͺ… : xss-1 λ‚œμ΄λ„ : Level 1 κ΄€λ ¨ κ°œλ… : Javascript, XSS, Cookie 문제 : XSS 취약점을 μ΄μš©ν•˜μ—¬ FLAG κ°’ νšλ“ XSS κ°•μ˜μ— ν¬ν•¨λœ μ›Œκ²Œμž„μž…λ‹ˆλ‹€. 2. μ†ŒμŠ€ μ½”λ“œ 확인 1) HTML μ†ŒμŠ€μ½”λ“œμ—λŠ” html λ¬Έ

goldsony.tistory.com

 

'SWLUG > μ›Ή ν•΄ν‚Ή' μΉ΄ν…Œκ³ λ¦¬μ˜ λ‹€λ₯Έ κΈ€

[Dreamhack/λ“œλ¦Όν•΅] xss-2  (0) 2023.11.06
[xss-game] Level 5: Breaking protocol  (3) 2023.11.06
[Dreamhack/λ“œλ¦Όν•΅] DOM XSS  (0) 2023.11.05
[los.rubiya.kr] orc  (1) 2023.10.07
[los.rubiya.kr] goblin  (1) 2023.10.06