-
-
Notifications
You must be signed in to change notification settings - Fork 44
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
Changes to contract CIDs (requires updating the chel command) #2494
base: master
Are you sure you want to change the base?
Changes to contract CIDs (requires updating the chel command) #2494
Conversation
multiformats/multicodec#369 merged |
…ing-malicious-contracts-from-being-loaded
…ing-malicious-contracts-from-being-loaded
…ing-malicious-contracts-from-being-loaded
…ing-malicious-contracts-from-being-loaded
…ing-malicious-contracts-from-being-loaded
Updated dependencies detected. Learn more about Socket for GitHub ↗︎
|
36d8709
to
942d1cb
Compare
group-income
|
Project |
group-income
|
Branch Review |
2115-investigate-potential-ways-of-preventing-malicious-contracts-from-being-loaded
|
Run status |
|
Run duration | 11m 43s |
Commit |
|
Committer | Ricardo Iván Vieitez Parra |
View all properties for this run ↗︎ |
Test results | |
---|---|
|
0
|
|
0
|
|
10
|
|
0
|
|
114
|
View all changes introduced in this branch ↗︎ |
…ing-malicious-contracts-from-being-loaded
…ing-malicious-contracts-from-being-loaded
…ing-malicious-contracts-from-being-loaded
7fdc3f7
to
6b02beb
Compare
…ing-malicious-contracts-from-being-loaded
6e6cd09
to
daef9a9
Compare
…ing-malicious-contracts-from-being-loaded
shared/domains/chelonia/utils.js
Outdated
export const CONTRACT_MANIFEST_REGEX: RegExp = /^zL7mM9d4Xb4T[123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{44}$/ | ||
export const CONTRACT_SOURCE_REGEX: RegExp = /^zLAeVmpcc88g[123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{44}$/ | ||
export const CONTRACT_DATA_REGEX: RegExp = /^zLDXeQ2AgfCu[123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{44}$/ | ||
export const FILE_MANIFEST_REGEX: RegExp = /^zLGQo2DimCH8{44}$/ | ||
export const FILE_CHUNK_REGEX: RegExp = /^zLKHweRGqjMM{44}$/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are the last two missing [123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bad copy & paste.
Gruntfile.js
Outdated
// This banner makes contracts easy to detect and harmless in the event | ||
// of accidental execution | ||
js: 'for(;;)"use shelter";' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please update this comment to say that the reason this is being added is to prevent people from uploading malicious contracts to our servers and then loading them elsewhere (e.g. via XSS or whatever).
EDIT: however, this isn't enforced server side, so it seems there's no point to it.
IMO, unless it's enforced server-side, we shouldn't have this as it's unnecessary complexity that accomplishes nothing. And if we enforce it server-side, then we can't support other languages — something we want.
So please could you remove this banner and related code?
…ing-malicious-contracts-from-being-loaded
This will probably fail until the
chel
command is updated. See https://github.com/okTurtles/chel/compare/1927-design-implement-contract-deletion-op_contract_delete-1.