https://soooprmx.com/archives/4056
https://opentutorials.org/module/2086/12091
import sqlite3 conn = sqlite3.connect("test.db") cur = conn.cursor()sql = "select * from customer where category=? and region=?"cur.execute(sql, (1, 'SEA'))rows = cur.fetchall()for row in rows: print(row) conn.close() #Namedsql = "select * from customer where id = :Id"cur.execute(sql, {"Id": 1})
import sqlite3 conn = sqlite3.connect("asdf.db") cur = conn.cursor()cur.execute("SELECT * FROM general") rows = cur.fetchall()for row in rows: print(row) conn.close() hyomin@ubuntu:~/flask_project$ python sql.py (1, u'\uc655\uac74', 89)(2, u'\ubc15\uc220\ud76c', 97)(3, u'\uc655\uc2dd\ub834', 84)(4, u'\uc2e0\uc22d\uacb8', 98)(5, u'\uad81\uc608', 77)(6, u'\uc720\uae08\ud544', 99)(7, u'\ub2a5\ud658..
>> sql_test.py import sqlite3 as liteimport time database_filename = 'test.db'conn = lite.connect(database_filename)cs = conn.cursor() #drop tablequery = "DROP TABLE IF EXISTS t1"cs.execute(query) #create tablequery = "CREATE TABLE IF NOT EXISTS t1 (id INTEGER PRIMARY_KEY NOT_NULL, name VARCHAR(255), at DATETIME)"cs.execute(query) #insert tablechars = "abcdefghijklmnopqrstuvwxyz"for a in range(l..
from flask import Flask, url_for app = Flask(__name__) @app.route('/') def index(): return 'index' @app.route('/login') def login(): return 'login' @app.route('/user/') def profile(username): return '{}\'s profile'.format(username) with app.test_request_context(): print(url_for('index')) print(url_for('login')) print(url_for('login', next='/')) print(url_for('profile', username='John Doe')) / /l..
$ export FLASK_ENV=development $ flask run
- rt_sigreturn
- tcache
- fsop
- overflow
- pwable
- FSB
- pwnable
- 해킹
- TLS
- fastbindup
- fastbin
- HackCTF
- hacking
- ebp change
- heap
- srop
- oob
- codegate
- 본선가고싶다
- shellcoding
- exit
- stack reusing
- pwnable.tw
- glibc
- SQLi
- Total
- Today
- Yesterday