Age | Commit message (Collapse) | Author |
|
Ref https://github.com/denoland/deno/issues/24129
`kty: "okp"` is defined in
[rfc8037](https://www.rfc-editor.org/rfc/rfc8037.html)
|
|
Fixes #25142
Signed-off-by: Caleb Lloyd <caleblloyd@gmail.com>
|
|
Fixes https://github.com/denoland/deno/issues/23531
|
|
(#25128)
Closes https://github.com/denoland/deno/issues/25117
|
|
|
|
Missed removing it before committing
|
|
The check in `tty.WriteStream.prototype.hasColors()` was incorrect
leading to the
[`yoctocolors`](https://github.com/sindresorhus/yoctocolors) package not
printing any colors.
Fixes https://github.com/denoland/deno/issues/24407
|
|
This PR addresses a regression introduced in
https://github.com/denoland/deno/pull/25021 that would cause the
`req.url` parameter in Node's http server to always be a single
character instead of the expected value. The regression was caused by
effectively calling `.indexOf()` on an empty string and thus passing the
wrong index for slicing.
```js
"".indexOf("/") // -> -1
request.url.slice(-1) // effectively only giving us the last character
```
Fixes https://github.com/denoland/deno/issues/25080
|
|
My fix in #25030 was buggy, I forgot to pass the `byteOffset` and
`byteLength`. Whoops.
I also discovered that fs.read was not respecting the `offset` argument,
and we were constructing a new `Buffer` for the callback instead of just
passing the original one (which is what node does, and the @types/node
definitions also indicate the callback should get the same type).
Fixes #25028.
|
|
Linux/macos only currently.
Part of https://github.com/denoland/deno/issues/23524 (fixes it on
platforms other than windows).
Part of #16899 (fixes it on platforms other than windows).
After this PR, playwright is functional on mac/linux.
|
|
Co-authored-by: Satya Rohith <me@satyarohith.com>
|
|
Uint8Array (#25030)
Part of #25028.
Our underlying read/write operations in `io` assume the buffer is a
Uint8Array, but we were passing in other typed arrays (in the case above
it was `Int8Array`).
|
|
There is no constructor code when creating an inspector `Session`
instance in Node. Also get rid of some symbols which should've been
private properties. This PR doesn't yet add any new implementations
though as these are mostly cosmetic changes.
|
|
For some reason we didn't register the `node:inspector` module, which
lead to a panic when trying to import it. This PR registers it.
Related: https://github.com/denoland/deno/issues/25004
|
|
|
|
make this http incoming constructor match with node, and also handle
arbitrary duplex inputs
|
|
|
|
Follow-on to
https://github.com/denoland/deno/pull/24216/files#r1642188672
|
|
**Changes**:
- Remove unsafe usage, rewrite Rust representation with `yoke`.
- Implement `X509Certificate.prototype.publicKey()`
Fixes https://github.com/denoland/deno/issues/23307
|
|
Fixes https://github.com/denoland/deno/issues/22919
|
|
Fixes https://github.com/denoland/deno/issues/24416
|
|
This is commonly used to register loading non standard file types. But
some libs also register TS loaders which Deno supports natively, like
the npm `payload` package. This PR unblocks those.
Fixes https://github.com/denoland/deno/issues/24902
|
|
- Return auth tag for GCM ciphers from auto padding shortcircuit
- Use _ring_ for ed25519 signing
---------
Co-authored-by: Divy Srivastava <dj.srivastava23@gmail.com>
|
|
For dd-trace tests to succeed, `OutgoingMessage` should be a function
instead of a class.
|
|
Co-Authored-By: Luca Casonato <hello@lcas.dev>
Fixes https://github.com/denoland/deno/issues/21804
Ref https://github.com/denoland/deno/issues/20924
---------
Signed-off-by: Divy Srivastava <dj.srivastava23@gmail.com>
Co-authored-by: Luca Casonato <hello@lcas.dev>
|
|
Add the missing `node:util.debug` export which is an alias of
`node:util.debuglog`, see
https://nodejs.org/api/util.html#utildebugsection
|
|
server (#24946)
Closes https://github.com/denoland/deno/issues/22820
|
|
(#24943)
Because public/private key are reassigned, they should be `let` instead
of `const`.
Co-authored-by: Divy Srivastava <dj.srivastava23@gmail.com>
|
|
Co-authored-by: Divy Srivastava <dj.srivastava23@gmail.com>
Closes #21806
|
|
This PR ensures that we forward a `rename` event in our file watcher.
The rust lib we use combines that with the `modify` event.
This fixes a compatibility issue with Node too, which sends the `rename`
event as well.
Fixes https://github.com/denoland/deno/issues/24880
|
|
This completely rewrites how we handle key material in ext/node. Changes
in this
PR:
- **Signing**
- RSA
- RSA-PSS 🆕
- DSA 🆕
- EC
- ED25519 🆕
- **Verifying**
- RSA
- RSA-PSS 🆕
- DSA 🆕
- EC 🆕
- ED25519 🆕
- **Private key import**
- Passphrase encrypted private keys 🆕
- RSA
- PEM
- DER (PKCS#1) 🆕
- DER (PKCS#8) 🆕
- RSA-PSS
- PEM
- DER (PKCS#1) 🆕
- DER (PKCS#8) 🆕
- DSA 🆕
- EC
- PEM
- DER (SEC1) 🆕
- DER (PKCS#8) 🆕
- X25519 🆕
- ED25519 🆕
- DH
- **Public key import**
- RSA
- PEM
- DER (PKCS#1) 🆕
- DER (PKCS#8) 🆕
- RSA-PSS 🆕
- DSA 🆕
- EC 🆕
- X25519 🆕
- ED25519 🆕
- DH 🆕
- **Private key export**
- RSA 🆕
- DSA 🆕
- EC 🆕
- X25519 🆕
- ED25519 🆕
- DH 🆕
- **Public key export**
- RSA
- DSA 🆕
- EC 🆕
- X25519 🆕
- ED25519 🆕
- DH 🆕
- **Key pair generation**
- Overhauled, but supported APIs unchanged
This PR adds a lot of new individual functionality. But most importantly
because
of the new key material representation, it is now trivial to add new
algorithms
(as shown by this PR).
Now, when adding a new algorithm, it is also widely supported - for
example
previously we supported ED25519 key pair generation, but we could not
import,
export, sign or verify with ED25519. We can now do all of those things.
|
|
rewrite vm implementation to increase compat.
vm.Module+importModuleDynamically callbacks should be added in a
followup.
|
|
Reverts denoland/deno#24402
deno_web can't depend on code in runtime
|
|
We are switching to ContinuationPreservedEmbedderData. This allows
adding async context tracking to the various async operations that deno
provides.
Fixes: https://github.com/denoland/deno/issues/7010
Fixes: https://github.com/denoland/deno/issues/22886
Fixes: https://github.com/denoland/deno/issues/24368
|
|
Fixes https://github.com/denoland/deno/issues/24572
|
|
|
|
This PR fixes various typos I spotted in the project.
|
|
randomFillSync (#24816)
|
|
- upgrade to v8 12.8
- optimizes DataView bigint methods
- fixes global interceptors
- includes CPED methods for ALS
- fix global resolution
- makes global resolution consistent using host_defined_options.
originally a separate patch but due to the global interceptor bug it
needs to be included in this pr for all tests to pass.
|
|
Makes `v8flags` package from NPM work.
|
|
The way `fs.watch` works is different in `node:fs/promises` than
`node:fs`. It has a different function signature and it returns an async
iterable instead, see
https://nodejs.org/api/fs.html#fspromiseswatchfilename-options
Fixes https://github.com/denoland/deno/issues/24661
|
|
This PR adds the experimental `scheduler` APIs in Node's
`timers/promises` module. See
https://nodejs.org/api/timers.html#timerspromisesschedulerwaitdelay-options
Fixes https://github.com/denoland/deno/issues/24800
|
|
Fixes https://github.com/denoland/deno/issues/24756. Fixes
https://github.com/denoland/deno/issues/24796.
This also gets vitest working when using
[`--pool=forks`](https://vitest.dev/guide/improving-performance#pool)
(which is the default as of vitest 2.0). Ref
https://github.com/denoland/deno/issues/23882.
---
This PR resolves a handful of issues with child_process IPC. In
particular:
- We didn't support sending typed array views over IPC
- Opening an IPC channel resulted in the event loop never exiting
- Sending a `null` over IPC would terminate the channel
- There was some UB in the read implementation (transmuting an `&[u8]`
to `&mut [u8]`)
- The `send` method wasn't returning anything, so there was no way to
signal backpressure (this also resulted in the benchmark
`child_process_ipc.mjs` being misleading, as it tried to respect
backpressure. That gave node much worse results at larger message sizes,
and gave us much worse results at smaller message sizes).
- We weren't setting up the `channel` property on the `process` global
(or on the `ChildProcess` object), and also didn't have a way to
ref/unref the channel
- Calling `kill` multiple times (or disconnecting the channel, then
calling kill) would throw an error
- Node couldn't spawn a deno subprocess and communicate with it over IPC
|
|
Fixes https://github.com/denoland/deno/issues/24323
- Use a Buffer pool for `fromString`
- Implement fast call base64 writes
- Direct from string `create` method for each encoding op
```
$ deno bench -A bench.mjs # 1.45.1+fee4d3a
cpu: Apple M1 Pro
runtime: deno 1.45.1+fee4d3a (aarch64-apple-darwin)
benchmark time (avg) (min … max) p75 p99 p999
----------------------------------------------------------- -----------------------------
Buffer.from base64 550 ns/iter (490 ns … 1'265 ns) 572 ns 606 ns 1'265 ns
Buffer#write base64 285 ns/iter (259 ns … 371 ns) 307 ns 347 ns 360 ns
$ ~/gh/deno/target/release/deno bench -A bench.mjs # this PR
cpu: Apple M1 Pro
runtime: deno dev (aarch64-apple-darwin)
benchmark time (avg) (min … max) p75 p99 p999
----------------------------------------------------------- -----------------------------
Buffer.from base64 151 ns/iter (145 ns … 770 ns) 148 ns 184 ns 648 ns
Buffer#write base64 62.58 ns/iter (60.79 ns … 157 ns) 61.65 ns 75.79 ns 141 ns
$ node bench.mjs # v22.4.0
cpu: Apple M1 Pro
runtime: node v22.4.0 (arm64-darwin)
benchmark time (avg) (min … max) p75 p99 p999
----------------------------------------------------------- -----------------------------
Buffer.from base64 163 ns/iter (96.92 ns … 375 ns) 99.45 ns 127 ns 220 ns
Buffer#write base64 75.48 ns/iter (74.97 ns … 134 ns) 75.17 ns 81.83 ns 96.84 ns
```
|
|
This commit duplicates ops from "ext/fetch" to "ext/node" to
kick off a bigger rewrite of "node:http".
Most of duplication is temporary and will be removed as these
ops evolve.
|
|
Closes #24768
|
|
Support `MessagePort.once` in Node mode and enable relevant
`worker_threads` test. Noticed that another Node test was passing as
well, so I enabled that too.
|
|
(#24656)
|
|
ones that fail) (#24631)
The intent is that those tests will be executed, but our check that the
files are up to date won't overwrite the contents of the tests. This is
useful when a test needs some manual edits to work.
It turns out we weren't actually running them.
---
This ended up turning into a couple of small bug fixes to get the tests
passing:
- We weren't canonicalizing the exec path properly (it sometimes still
had `..` or `.` in it)
- We weren't accepting strings in `process.exit`
There was one failure I couldn't figure out quickly, so I disabled the
test for now, and filed a follow up issue: #24694
|
|
We were missing an import of `emitWarning` in our streams
implementation. The code prior to this PR assumed that `process` would
be available as a global.
Fixes https://github.com/denoland/deno/issues/23709
---------
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
|