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

Use base64url for cloudinary identifiers, not cuid2 #8724

Merged
merged 2 commits into from
Jul 31, 2023
Merged

Conversation

dcousens
Copy link
Member

@dcousens dcousens commented Jul 31, 2023

This pull request switches from cuid2 (a dependency) to a node:crypto call that doesn't potentially fallback to Math.random.
To my knowledge, there is no requirement for Cloudinary to use cuid or similar, and we could drop this dependency easily.

randomBytes(20).toString('base64url') is url safe.

@changeset-bot

This comment was marked as resolved.

@dcousens dcousens self-assigned this Jul 31, 2023
@dcousens dcousens requested a review from borisno2 July 31, 2023 07:05
@codesandbox-ci
Copy link

codesandbox-ci bot commented Jul 31, 2023

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 35bc45f:

Sandbox Source
@keystone-6/sandbox Configuration

@dcousens dcousens merged commit c3e848b into main Jul 31, 2023
57 checks passed
@dcousens dcousens deleted the no-cuid2-cloudinary branch July 31, 2023 07:46
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