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

feat(std/http): Check if cookie property is valid #7189

Merged
merged 20 commits into from
Nov 17, 2020
Merged
Changes from 1 commit
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
3b32477
feat(std/http): Check if cookie propery is valid
getspooky Aug 26, 2020
979a13b
test(std/http): Testing Cookie propery validation
getspooky Aug 26, 2020
27b17a8
fix(std/http): Format & Linting cookie.ts file
getspooky Aug 26, 2020
312c823
perf(srd/http): Use assertThrows for testing cookie validation
getspooky Aug 26, 2020
3661729
fix(std/http): Expected error to be instance of TypeError but was Den…
getspooky Aug 27, 2020
74b7a6f
reset CI
getspooky Aug 27, 2020
d23aadd
Merge branch 'master' into my-new-dev
ry Oct 26, 2020
cc4ef6b
x
ry Oct 26, 2020
25dbc3e
fix(srd/http): Match any US-ASCII except control characters, spaces, …
getspooky Nov 8, 2020
7b8721f
test(std/http): Cookie Validation testing
getspooky Nov 8, 2020
6c983c8
Merge branch 'my-new-dev' of https://github.com/getspooky/deno into m…
getspooky Nov 8, 2020
087c8b8
Merge remote-tracking branch 'upstream/master' into my-new-dev
getspooky Nov 8, 2020
b9419e0
fix(src/http): Fix linting
getspooky Nov 11, 2020
a654b6b
fix(std/http/cookie.ts): Remove validateCookieProperty from domain
getspooky Nov 14, 2020
163cebd
fix(std/http): Remove path validateCookieProperty
getspooky Nov 14, 2020
463ebf8
refafator(std/http): Rename validateCookieProperty to validateCookieName
getspooky Nov 14, 2020
bb534ad
fix(std/http): Use validateCookieName validation
getspooky Nov 14, 2020
3887d42
fix(std/http): Restrict to ASCII, excluding control characters
getspooky Nov 14, 2020
0b96870
fix(std/http): Return cookie validation error message
getspooky Nov 14, 2020
3bad681
test(std/http): Test cookie name illegal characters
getspooky Nov 17, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix(srd/http): Match any US-ASCII except control characters, spaces, …
…tabs, separator character
  • Loading branch information
getspooky committed Nov 8, 2020
commit 25dbc3e1e31094adfbe14576d7b359ee27ef3cb0
2 changes: 1 addition & 1 deletion std/http/cookie.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export interface Cookie {

export type SameSite = "Strict" | "Lax" | "None";

const FIELD_CONTENT_REGEXP = /^[\u0009\u0020-\u007e\u0080-\u00ff]+$/;
const FIELD_CONTENT_REGEXP = /^[^()@<>,;:\\"\[\]?={}\s]+$/;
getspooky marked this conversation as resolved.
Show resolved Hide resolved

function toString(cookie: Cookie): string {
if (!cookie.name) {
Expand Down