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

Code Optimization and Security issue fixed #46

Merged
merged 5 commits into from
Sep 10, 2023
Merged

Code Optimization and Security issue fixed #46

merged 5 commits into from
Sep 10, 2023

Conversation

sentayhu19
Copy link
Collaborator

@sentayhu19 sentayhu19 commented Nov 17, 2022

In this PR

  • Security issue with Math.random() fixed by utilizing the randomBytes
  • Code optimized using the compute function to execute the generation of the random string for alphanumeric, range, hex, alphabet, and alphanumeric given option length, characters, and length` in the asset.

@sentayhu19 sentayhu19 self-assigned this Mar 14, 2023
Copy link
Owner

@Dagic-zewdu Dagic-zewdu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @sentayhu19 ,

Good job so far!
There are some issues that you still need to work on to prepare your project for the final evaluation but you are almost there!

Suggested changes

Check the comments under the review.

lib/index.js Outdated
result = (0, check_option_1.checkOptions)(result, option);
}
}
return result;
};
exports.generate = generate;
var compute = function (type, optlen, length) {
var res = "";
console.log("COMPUTE RUNNNNNNING.....................", length, "TYPE", optlen);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • please remove this console.log it shows unnecessary messages while using the package

@sentayhu19 sentayhu19 changed the title Code Optimization Code Optimization and Security issue fixed Sep 6, 2023
Copy link
Owner

@Dagic-zewdu Dagic-zewdu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @sentayhu19 ,

STATUS: APPROVED ✔️

Cheers and Happy coding!👏👏👏

Feel free to leave any questions or comments in the PR thread if something is not 100% clear.

@Dagic-zewdu Dagic-zewdu merged commit 51401d7 into dev Sep 10, 2023
3 checks passed
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

Successfully merging this pull request may close these issues.

2 participants