Ask questions--allow-net=:8080 broken

If any code uses shorthand notation:

import { serve } from ""
const PORT = 8080

then any variant of

deno run --allow-net=:8080 server.ts
deno run --allow-net=localhost:8080 server.ts
deno run --allow-net= server.ts
deno run --allow-net= server.ts


Unfortunately, a lot of libraries in x use this pattern which makes locking down permissions impossible without forking all those libraries.


Answer questions jsouto18

I've tested this on the latest release and I've managed to execute the code successfully running deno run --allow-net=:8080 server.ts or deno run --allow-net= server.ts which seems to be the intended behaviour as the serve function binds to @ry is this the intended behaviour? The only other thing I found odd was trying to run serve( and running deno run --allow-net=localhost:8080 server.ts fails because localhost is not resolved to the configured IP, for example in /etc/hosts.


Related questions

{WSL 2} Permission denied (os error 13) hot 1
gRPC in Deno? hot 1
deno remove/uninstall subcommand hot 1
Insight required: Resource (TCP) errors hot 1
TCP accept loop doesn't use for-await hot 1
Support d.ts files hot 1
Restore runtime lib generation capability hot 1
disable flaky tests _048_media_types_jsx and _019_media_types hot 1
Typescript Custom Transformers Support hot 1
reorg directory structure hot 1
Centos 7 GLIBC_2.18 not found hot 1
"deno ast script.ts" hot 1
Text decoding performance abysmally slow. hot 1
"deno ast script.ts" hot 1
Can't build master hot 1
Github User Rank List