所以我正在做一个任务,并作为其中的一部分,执行一个SQL注入我名为测试,从一个表格用于输入表中名为学生。SQL注入语法错误试图删除表
我一直在试图
'; DROP TABLE test; --
我得到这个错误
Error: INSERT INTO student (student_id, first_name, last_name, DOB, sex, phone, user_id) VALUES ('nhdb', ''; DROP TABLE test; -- ', '', '', '', '', 'u01')
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near
'; DROP TABLE test; -- ', '', '', '', '', 'u01')'
at line 1
本来我是想放弃的学生表,但是当我在测试用户是否不得不放弃的权利该表中,有外键约束问题。所以我把一个名为test的表放在一起,这个表可以被用户丢弃而没有问题。
任何指导我要去哪里错了?我相信'; DROP TABLE test; --
应该工作。
谢谢你解决了它 – nwalmaer