1682 bug supertask builder does not work properly#609
1682 bug supertask builder does not work properly#609LuffyNoNika wants to merge 4 commits intomasterfrom
Conversation
|
There probably was a misunderstanding. The idea for the supertask builder is to use the two backend helpers which then will take care of the creation of all the preconfigured task and the supertask. The two helpers take the inputs from the mask input (plus the flags) or the bulk wordlist selections and inputs and then do everything in the backend. There the logic and code already exists for all the edge cases and handling. |
I just saw the two endpoints that are mentioned in the issue description after seeing you comment. My fault, it was a misunderstanding from my side. I'll do it again as desired. Thanks. |
|
Reimplementation ready. Frontend now delegates to backend helpers: -mask.component.ts: onSubmit method does makes a POSTs to maskSuperTaskBuilder helper. Backend already knew how to parse hcmask, so frontend sends the masks as-is, exactly as written by the user. -wrbulk.component.ts: createSupertask method now POSTs to bulkSupertaskBuilder helper. The existing client-side validations in onSubmit method are preserved before reaching createSupertask method. -mask.component.spec.ts: 24 tests covering form initialization, payload field mapping, success/error flow, and hcmask edge cases.. -wrbulk.component.spec.ts: 21 tests covering form initialization, the 4 client-side validations, payload field mapping, success/error flow, getFormdata and onUpdateForm. |
changes:
-new utility file hcmask.ts with a method that splits the line by "," and assumes that up to 4 leading fields are custom charset definitions and the last field is the mask itself. If the mask does not reference any of the defined custom charsets (?1–?4), the line is treated as a plain mask to prevent false positives.
-mask.component.ts now filters empty lines to avoid creating empty pretasks through the use of the method from hcmask.ts to build the correct attackcmd with charset flags. it sets taskName to the parsed mask only, not the raw hcmask line as it used to.
-tests added for hcmask covering plain masks, 1-4 custom charsets, fallback when commas are present but no custom charsets are referenced and edge cases.