5

I am trying to make sqlmap to avoid fetch data from stored session. How do I achieve that? I have performed sqlmap check once on a target and now that target is offline, I want sqlmap to just stop the checks if target is offline and even if target is online it should recheck it not just show the data from stored session.

python3 sqlmap.py --threads=5 -m /tmp/sql --batch --answers "already=N"
[12:39:54] [CRITICAL] unable to connect to the target URL ('Connection refused')
sqlmap resumed the following injection point(s) from stored session:
---
Parameter: id2 (GET)
    Type: boolean-based blind
    Title: AND boolean-based blind - WHERE or HAVING clause
    Payload: id2=1 AND 9749=9749

    Type: UNION query
    Title: Generic UNION query (NULL) - 2 columns
    Payload: id2=1 UNION ALL SELECT NULL,'qzvpq'||'GUyWfclrkLkxNLVAdYrBXilkXpGmcpZLkJplITTj'||'qqbbq'-- qdhG

2 Answers 2

12

use --flush-session

sample: sqlmap --flush-session -u ....

1
  • Did it for me, don't know why it had been downvoted...
    – borizzzzz
    Commented Dec 8, 2021 at 12:35
1

You will want to use the fresh queries switch:

    --fresh-queries     Ignore query results stored in session file
1
  • No, it doesn't work. I am getting the same behaviour even if use it. Commented Sep 22, 2020 at 13:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .