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

Failure to update 1+n scan configuration in Manage Scans #484

Closed
secbyd opened this Issue Jun 28, 2017 · 4 comments

Comments

Projects
2 participants
@secbyd

secbyd commented Jun 28, 2017

  • Editing and updating first scan completes successfully.
  • Editing and updating second scan fails

Update button changes to "Updating..." but process does not complete.
Closing and reopening the editing page does not help. The edit page does actually show the proposed changes but fails to store them in the back-end/represent them on the overview page.

A full refresh of the page is the only option.

@seccubus seccubus self-assigned this Jun 28, 2017

@seccubus seccubus added the bug label Jun 28, 2017

@seccubus seccubus added this to the 2017Q3 milestone Jun 28, 2017

@seccubus

This comment has been minimized.

Member

seccubus commented Jun 28, 2017

After running t/53_scans in the first workspace editing the first scan works, but editing the second scan doesn't.
PUT /api/workspace/100/scan/3
JSON:

{"findCount":"","lastScan":null,"name":"nessusZ","notifications":"0","parameters":"paramsZ","password":"passwordZ","runs":"0","scanner":"Nessus6Z","targets":"localhost\\n127.0.0.1","workspace":"100","id":"1"}

response:

{"message":"A scan named nessusZ already exists in this workspace at lib\/Seccubus\/Scans.pm line 253.\n","status":"Error"}
@seccubus

This comment has been minimized.

Member

seccubus commented Jun 28, 2017

If I update the second scan first, things work out ok.
PUT /api/workspace/100/scan/3

{"findCount":"","lastScan":null,"name":"nessusZ","notifications":"0","parameters":"paramsZ","password":"passwordZ","runs":"0","scanner":"Nessus6Z","targets":"localhost\\n127.0.0.1","workspace":"100","id":"1"}
@seccubus

This comment has been minimized.

Member

seccubus commented Jun 28, 2017

It looks like it is somehow confusing IDs

@seccubus

This comment has been minimized.

Member

seccubus commented Jun 28, 2017

Apparently their is some weird caching going on. url to the api funcitons seems to be passed by reference and not by value as I had expected. Therefore the funciton was changing what should have been a constant.

@seccubus seccubus closed this in 1021851 Jun 29, 2017

seccubus added a commit that referenced this issue Jun 29, 2017

Merge pull request #486 from /issues/484-edit-n+1
Fixes #484 - Failure to update 1+n scan configuration in Manage Scans…

@seccubus seccubus added this to Done in 2017Q3 Jul 3, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment