Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

--sql-file Inquiry #4708

Open
AmericanY opened this issue Jun 11, 2021 · 4 comments
Open

--sql-file Inquiry #4708

AmericanY opened this issue Jun 11, 2021 · 4 comments

Comments

@AmericanY
Copy link

Hello,

I'm trying to use the following argument --sql-file

    --sql-file=SQLFILE  Execute SQL statements from given file(s)

According to the documentation it's will run sql statement(s) from file.

  1. i noticed that the file should be saved with EXT .sql in order to detect it.
  2. the file should inserted with it's PATH --sql-file="PATH/sqlfile.sql" otherwise sqlmap will look for it into /sqlmap/data/procs/mysql/sqlfile.sql.
  3. Now my issue is: i already specified the PATH to the file but sqlmap unable to run the statement !
[19:53:01] [INFO] executing SQL statements from given file(s)
[19:53:01] [ERROR] unresolved variables 'm, m' in SQL file '/path_to_file/sqlfile'

is the sql statement need to be formatted ? as i inserted it as single line such as SELECT A, B FROM DB.TABLE

Thanks in advance as well.

@AmericanY
Copy link
Author

I walked through the code

msg = "do you want to provide the substitution values? [y/N] "
but i didn't get how the scenario done here! can someone show me an example of that ?

cc @stamparm

@AmericanY
Copy link
Author

also i do have another question, is there a way where i can save my dump to a file directly ?

Note: am not about --output=

Example, if i used sql-query= or sql-shell and used sql statement, i would like to save the output only. currently am viewing the output from sqlmap output log

@kevin659591
Copy link

#4833

@sharifulgeo
Copy link

@AmericanY #5238

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants