How to fix ERR_UNSAFE_PORT error on Chrome when browsing to unsafe portsWhich ports are considered unsafe on...

Citing paywalled articles accessed via illegal web sharing

Is there a Linux system call to create a “view” of a range of a file?

Graph with overlapping labels

Mathematics and the art of linearizing the circle

What is a good reason for every spaceship to carry a weapon on board?

SET NOCOUNT Error in handling SQL call after upgrade

Cat is tipping over bed-side lamps during the night

Why is it that Bernie Sanders is always called a "socialist"?

Numbers with a minus sign in a matrix not aligned with the numbers wihtout minus sign

Do authors have to be politically correct in article-writing?

Quickly creating a sparse array

Do theoretical physics suggest that gravity is the exchange of gravitons or deformation/bending of spacetime?

Why was Lupin comfortable with saying Voldemort's name?

Finding a logistic regression model which can achieve zero error on a training set training data for a binary classification problem with two features

Making him into a bully (how to show mild violence)

Has any human ever had the choice to leave Earth permanently?

What is the purpose of easy combat scenarios that don't need resource expenditure?

How do you funnel food off a cutting board?

Cookies - Should the toggles be on?

using 'echo' & 'printf' in bash function calls

Removing disk while game is suspended

Slow While Loop, Query Improvment Assistance

Am I a Rude Number?

Is it possible to grant users sftp access without shell access? If yes, how is it implemented?



How to fix ERR_UNSAFE_PORT error on Chrome when browsing to unsafe ports


Which ports are considered unsafe on ChromeChrome Error 330 (net::ERR_CONTENT_DECODING_FAILED)Error 310 in Chrome when browsing to a certain web siteResolve ERR_EMPTY_RESPONSE error on Chrome or any BrowserChrome error when resolving URLs for the first timeHow to “load unsafe script” in google chrome frameHow to update chrome browser without uninstall ( for error 1 )?NET::ERR_CERT_DATE_INVALID error in Chrome when browsing python.org or github.comChrome cache protocol: avoid too many redirectsHow to see HTTP errors like Chrome in FirefoxPrevent Chrome from executing Google Search when address bar content starts with //













73















I'm getting this error when connecting to a web server on port 6666 (http://myserver:6666/):



Error 312 (net::ERR_UNSAFE_PORT): Unknown error.



Is there an easy way to resolve this without rebuilding Chrome from source?










share|improve this question





























    73















    I'm getting this error when connecting to a web server on port 6666 (http://myserver:6666/):



    Error 312 (net::ERR_UNSAFE_PORT): Unknown error.



    Is there an easy way to resolve this without rebuilding Chrome from source?










    share|improve this question



























      73












      73








      73


      24






      I'm getting this error when connecting to a web server on port 6666 (http://myserver:6666/):



      Error 312 (net::ERR_UNSAFE_PORT): Unknown error.



      Is there an easy way to resolve this without rebuilding Chrome from source?










      share|improve this question
















      I'm getting this error when connecting to a web server on port 6666 (http://myserver:6666/):



      Error 312 (net::ERR_UNSAFE_PORT): Unknown error.



      Is there an easy way to resolve this without rebuilding Chrome from source?







      google-chrome






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Sep 13 '10 at 12:35







      ripper234

















      asked Sep 13 '10 at 9:40









      ripper234ripper234

      4,4133073105




      4,4133073105






















          7 Answers
          7






          active

          oldest

          votes


















          68














          On Windows:



          Right Click on Chrome shortcut >> Properties >>



          Then Append
          --explicitly-allowed-ports=xxx to shortcut target



          Example:




          C:Documents and SettingsUserLocal
          SettingsApplication
          DataGoogleChromeApplicationchrome.exe
          --explicitly-allowed-ports=6666




          Resource from here






          share|improve this answer





















          • 1





            I missed this answer, thanks. I opened a separate question to understand which ports are safe/blocked by default: superuser.com/questions/188058/…

            – ripper234
            Sep 13 '10 at 12:36






          • 2





            This answer is excellent... for Windows. It won't solve the problem for (for example) Mac.

            – Chris R
            May 3 '12 at 17:23











          • @ChrisR: Why? Does the --explicitly-allowed-ports switch not exist for Mac?

            – Dennis
            May 3 '12 at 17:35






          • 2





            Adding command line flags on the mac is a pain in the ass; if you add them to the app bundle they often get nuked in upgrades.

            – Chris R
            May 3 '12 at 17:39











          • @ChrisR: You should consider adding this to your question.

            – Dennis
            May 3 '12 at 17:44



















          17














          You may be able to turn this off in Google Chrome, but you do so at your own risk. There is actually a good security reason why Chrome blocks these ports: Basically you open your browser up to being an open proxy for attackers to use to attack other services on your network.



          For more information: Why does Chrome consider some ports unsafe?






          share|improve this answer





















          • 1





            Why just making an HTTP request on a non standard port it is said to "open" the browser to being an open proxy to attack services in local network? Open how??

            – jj_
            Jul 22 '16 at 19:59











          • If it is left unchecked then any malicious code can make request to URLs with arbitrary ports. It might not be an optimal solution but by blocking other ports you are only leaving attackers with 80 & 443 to exploit.

            – Willa
            Jan 23 '17 at 14:39











          • the referenced link is now dead

            – Jeff Puckett
            Jun 13 '17 at 15:41











          • Link is now dead. Wayback Machine: web.archive.org/web/20170216040700/https://jazzy.id.au/2012/08/… (suggested edit)

            – Nulano
            Jun 26 '17 at 17:54













          • Link is now fixed on the server (server had an incorrectly configured timezone causing it to serve the blog post at the wrong date).

            – James Roper
            Jun 27 '17 at 13:47



















          7














          On Mac you can create an app launching Chrome with parameters mentioned in other answers using Automator built-in Apple application:




          1. Launch Automator


          2. As "Type of document" choose "Application"


          3. Add action "Run shell script"


          4. Replace placeholder cat script in this action with:



          /Applications/Google Chrome.app/Contents/MacOS/Google Chrome --explicitly-allowed-ports=5000,6000,7000




          1. Save the created app as something like "Google Chrome with allowed unsafe ports" in your Application folder


          2. Use this new app instead of Google Chrome directly


          3. (optional) Replace default icon of the created "app" - Automator's robot - with Chrome's using this method (note: upvote that answer if you like it!)



          Source: http://cubewot.de/node/266



          image






          share|improve this answer


























          • This picture does not have the full path. It is automating the execution of a directory.

            – ojblass
            Sep 19 '18 at 4:27



















          4














          For Mac:



          /Applications/Google Chrome.app/Contents/MacOS/Google Chrome --explicitly-allowed-ports=5000,6000,7000


          for ports 5000, 6000, and 7000.






          share|improve this answer































            3














            As subanki said, you've got to add the -explicitly-allowed-ports option to your Chrome startup command.



            In Ubuntu you can do this (as root) by editing the "google-chrome" script under your Chrome installation folder



            You can get the directory by typing:



            ls -la /usr/bin | grep chrome


            Then, edit the "google-chrome" file adding the mentioned switch to the EXEC line:



            exec -a "$0" "$HERE/chrome" "-explicitly-allowed-ports=6000" "$@"


            Just change "6000" with the comma separated values you might need (example: -explicitly-allowed-ports=5000,6000,7000)



            NOTE: for UNIX, the switch does NOT start with "--", it does with a single "-"






            share|improve this answer

































              0














              Here is the correct answer for those of you who are developers using node.js as a web server

              Change the port you are using to host your web pages.

              For example

              if you typed into command line node index.js & pressed enter,

              if it started running on port 22 for 80 http request,

              when you visit the website at port 22,

              the chrome browser with throw this error page.,br>
              keyword UNSAFE PORT means port needs to match the content.

              Thank you.






              share|improve this answer































                0














                I still get error



                http://localhost:6000/upload net::ERR_UNSAFE_PORT


                after starting chrome using automator...any ideas why?





                share








                New contributor




                Lucas Franco is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.




















                  Your Answer








                  StackExchange.ready(function() {
                  var channelOptions = {
                  tags: "".split(" "),
                  id: "3"
                  };
                  initTagRenderer("".split(" "), "".split(" "), channelOptions);

                  StackExchange.using("externalEditor", function() {
                  // Have to fire editor after snippets, if snippets enabled
                  if (StackExchange.settings.snippets.snippetsEnabled) {
                  StackExchange.using("snippets", function() {
                  createEditor();
                  });
                  }
                  else {
                  createEditor();
                  }
                  });

                  function createEditor() {
                  StackExchange.prepareEditor({
                  heartbeatType: 'answer',
                  autoActivateHeartbeat: false,
                  convertImagesToLinks: true,
                  noModals: true,
                  showLowRepImageUploadWarning: true,
                  reputationToPostImages: 10,
                  bindNavPrevention: true,
                  postfix: "",
                  imageUploader: {
                  brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
                  contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
                  allowUrls: true
                  },
                  onDemand: true,
                  discardSelector: ".discard-answer"
                  ,immediatelyShowMarkdownHelp:true
                  });


                  }
                  });














                  draft saved

                  draft discarded


















                  StackExchange.ready(
                  function () {
                  StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f188006%2fhow-to-fix-err-unsafe-port-error-on-chrome-when-browsing-to-unsafe-ports%23new-answer', 'question_page');
                  }
                  );

                  Post as a guest















                  Required, but never shown

























                  7 Answers
                  7






                  active

                  oldest

                  votes








                  7 Answers
                  7






                  active

                  oldest

                  votes









                  active

                  oldest

                  votes






                  active

                  oldest

                  votes









                  68














                  On Windows:



                  Right Click on Chrome shortcut >> Properties >>



                  Then Append
                  --explicitly-allowed-ports=xxx to shortcut target



                  Example:




                  C:Documents and SettingsUserLocal
                  SettingsApplication
                  DataGoogleChromeApplicationchrome.exe
                  --explicitly-allowed-ports=6666




                  Resource from here






                  share|improve this answer





















                  • 1





                    I missed this answer, thanks. I opened a separate question to understand which ports are safe/blocked by default: superuser.com/questions/188058/…

                    – ripper234
                    Sep 13 '10 at 12:36






                  • 2





                    This answer is excellent... for Windows. It won't solve the problem for (for example) Mac.

                    – Chris R
                    May 3 '12 at 17:23











                  • @ChrisR: Why? Does the --explicitly-allowed-ports switch not exist for Mac?

                    – Dennis
                    May 3 '12 at 17:35






                  • 2





                    Adding command line flags on the mac is a pain in the ass; if you add them to the app bundle they often get nuked in upgrades.

                    – Chris R
                    May 3 '12 at 17:39











                  • @ChrisR: You should consider adding this to your question.

                    – Dennis
                    May 3 '12 at 17:44
















                  68














                  On Windows:



                  Right Click on Chrome shortcut >> Properties >>



                  Then Append
                  --explicitly-allowed-ports=xxx to shortcut target



                  Example:




                  C:Documents and SettingsUserLocal
                  SettingsApplication
                  DataGoogleChromeApplicationchrome.exe
                  --explicitly-allowed-ports=6666




                  Resource from here






                  share|improve this answer





















                  • 1





                    I missed this answer, thanks. I opened a separate question to understand which ports are safe/blocked by default: superuser.com/questions/188058/…

                    – ripper234
                    Sep 13 '10 at 12:36






                  • 2





                    This answer is excellent... for Windows. It won't solve the problem for (for example) Mac.

                    – Chris R
                    May 3 '12 at 17:23











                  • @ChrisR: Why? Does the --explicitly-allowed-ports switch not exist for Mac?

                    – Dennis
                    May 3 '12 at 17:35






                  • 2





                    Adding command line flags on the mac is a pain in the ass; if you add them to the app bundle they often get nuked in upgrades.

                    – Chris R
                    May 3 '12 at 17:39











                  • @ChrisR: You should consider adding this to your question.

                    – Dennis
                    May 3 '12 at 17:44














                  68












                  68








                  68







                  On Windows:



                  Right Click on Chrome shortcut >> Properties >>



                  Then Append
                  --explicitly-allowed-ports=xxx to shortcut target



                  Example:




                  C:Documents and SettingsUserLocal
                  SettingsApplication
                  DataGoogleChromeApplicationchrome.exe
                  --explicitly-allowed-ports=6666




                  Resource from here






                  share|improve this answer















                  On Windows:



                  Right Click on Chrome shortcut >> Properties >>



                  Then Append
                  --explicitly-allowed-ports=xxx to shortcut target



                  Example:




                  C:Documents and SettingsUserLocal
                  SettingsApplication
                  DataGoogleChromeApplicationchrome.exe
                  --explicitly-allowed-ports=6666




                  Resource from here







                  share|improve this answer














                  share|improve this answer



                  share|improve this answer








                  edited Sep 14 '16 at 13:28









                  Greg Dubicki

                  23528




                  23528










                  answered Sep 13 '10 at 10:03









                  subankisubanki

                  5,94173246




                  5,94173246








                  • 1





                    I missed this answer, thanks. I opened a separate question to understand which ports are safe/blocked by default: superuser.com/questions/188058/…

                    – ripper234
                    Sep 13 '10 at 12:36






                  • 2





                    This answer is excellent... for Windows. It won't solve the problem for (for example) Mac.

                    – Chris R
                    May 3 '12 at 17:23











                  • @ChrisR: Why? Does the --explicitly-allowed-ports switch not exist for Mac?

                    – Dennis
                    May 3 '12 at 17:35






                  • 2





                    Adding command line flags on the mac is a pain in the ass; if you add them to the app bundle they often get nuked in upgrades.

                    – Chris R
                    May 3 '12 at 17:39











                  • @ChrisR: You should consider adding this to your question.

                    – Dennis
                    May 3 '12 at 17:44














                  • 1





                    I missed this answer, thanks. I opened a separate question to understand which ports are safe/blocked by default: superuser.com/questions/188058/…

                    – ripper234
                    Sep 13 '10 at 12:36






                  • 2





                    This answer is excellent... for Windows. It won't solve the problem for (for example) Mac.

                    – Chris R
                    May 3 '12 at 17:23











                  • @ChrisR: Why? Does the --explicitly-allowed-ports switch not exist for Mac?

                    – Dennis
                    May 3 '12 at 17:35






                  • 2





                    Adding command line flags on the mac is a pain in the ass; if you add them to the app bundle they often get nuked in upgrades.

                    – Chris R
                    May 3 '12 at 17:39











                  • @ChrisR: You should consider adding this to your question.

                    – Dennis
                    May 3 '12 at 17:44








                  1




                  1





                  I missed this answer, thanks. I opened a separate question to understand which ports are safe/blocked by default: superuser.com/questions/188058/…

                  – ripper234
                  Sep 13 '10 at 12:36





                  I missed this answer, thanks. I opened a separate question to understand which ports are safe/blocked by default: superuser.com/questions/188058/…

                  – ripper234
                  Sep 13 '10 at 12:36




                  2




                  2





                  This answer is excellent... for Windows. It won't solve the problem for (for example) Mac.

                  – Chris R
                  May 3 '12 at 17:23





                  This answer is excellent... for Windows. It won't solve the problem for (for example) Mac.

                  – Chris R
                  May 3 '12 at 17:23













                  @ChrisR: Why? Does the --explicitly-allowed-ports switch not exist for Mac?

                  – Dennis
                  May 3 '12 at 17:35





                  @ChrisR: Why? Does the --explicitly-allowed-ports switch not exist for Mac?

                  – Dennis
                  May 3 '12 at 17:35




                  2




                  2





                  Adding command line flags on the mac is a pain in the ass; if you add them to the app bundle they often get nuked in upgrades.

                  – Chris R
                  May 3 '12 at 17:39





                  Adding command line flags on the mac is a pain in the ass; if you add them to the app bundle they often get nuked in upgrades.

                  – Chris R
                  May 3 '12 at 17:39













                  @ChrisR: You should consider adding this to your question.

                  – Dennis
                  May 3 '12 at 17:44





                  @ChrisR: You should consider adding this to your question.

                  – Dennis
                  May 3 '12 at 17:44













                  17














                  You may be able to turn this off in Google Chrome, but you do so at your own risk. There is actually a good security reason why Chrome blocks these ports: Basically you open your browser up to being an open proxy for attackers to use to attack other services on your network.



                  For more information: Why does Chrome consider some ports unsafe?






                  share|improve this answer





















                  • 1





                    Why just making an HTTP request on a non standard port it is said to "open" the browser to being an open proxy to attack services in local network? Open how??

                    – jj_
                    Jul 22 '16 at 19:59











                  • If it is left unchecked then any malicious code can make request to URLs with arbitrary ports. It might not be an optimal solution but by blocking other ports you are only leaving attackers with 80 & 443 to exploit.

                    – Willa
                    Jan 23 '17 at 14:39











                  • the referenced link is now dead

                    – Jeff Puckett
                    Jun 13 '17 at 15:41











                  • Link is now dead. Wayback Machine: web.archive.org/web/20170216040700/https://jazzy.id.au/2012/08/… (suggested edit)

                    – Nulano
                    Jun 26 '17 at 17:54













                  • Link is now fixed on the server (server had an incorrectly configured timezone causing it to serve the blog post at the wrong date).

                    – James Roper
                    Jun 27 '17 at 13:47
















                  17














                  You may be able to turn this off in Google Chrome, but you do so at your own risk. There is actually a good security reason why Chrome blocks these ports: Basically you open your browser up to being an open proxy for attackers to use to attack other services on your network.



                  For more information: Why does Chrome consider some ports unsafe?






                  share|improve this answer





















                  • 1





                    Why just making an HTTP request on a non standard port it is said to "open" the browser to being an open proxy to attack services in local network? Open how??

                    – jj_
                    Jul 22 '16 at 19:59











                  • If it is left unchecked then any malicious code can make request to URLs with arbitrary ports. It might not be an optimal solution but by blocking other ports you are only leaving attackers with 80 & 443 to exploit.

                    – Willa
                    Jan 23 '17 at 14:39











                  • the referenced link is now dead

                    – Jeff Puckett
                    Jun 13 '17 at 15:41











                  • Link is now dead. Wayback Machine: web.archive.org/web/20170216040700/https://jazzy.id.au/2012/08/… (suggested edit)

                    – Nulano
                    Jun 26 '17 at 17:54













                  • Link is now fixed on the server (server had an incorrectly configured timezone causing it to serve the blog post at the wrong date).

                    – James Roper
                    Jun 27 '17 at 13:47














                  17












                  17








                  17







                  You may be able to turn this off in Google Chrome, but you do so at your own risk. There is actually a good security reason why Chrome blocks these ports: Basically you open your browser up to being an open proxy for attackers to use to attack other services on your network.



                  For more information: Why does Chrome consider some ports unsafe?






                  share|improve this answer















                  You may be able to turn this off in Google Chrome, but you do so at your own risk. There is actually a good security reason why Chrome blocks these ports: Basically you open your browser up to being an open proxy for attackers to use to attack other services on your network.



                  For more information: Why does Chrome consider some ports unsafe?







                  share|improve this answer














                  share|improve this answer



                  share|improve this answer








                  edited Jun 27 '17 at 13:46

























                  answered Aug 23 '12 at 7:42









                  James RoperJames Roper

                  55956




                  55956








                  • 1





                    Why just making an HTTP request on a non standard port it is said to "open" the browser to being an open proxy to attack services in local network? Open how??

                    – jj_
                    Jul 22 '16 at 19:59











                  • If it is left unchecked then any malicious code can make request to URLs with arbitrary ports. It might not be an optimal solution but by blocking other ports you are only leaving attackers with 80 & 443 to exploit.

                    – Willa
                    Jan 23 '17 at 14:39











                  • the referenced link is now dead

                    – Jeff Puckett
                    Jun 13 '17 at 15:41











                  • Link is now dead. Wayback Machine: web.archive.org/web/20170216040700/https://jazzy.id.au/2012/08/… (suggested edit)

                    – Nulano
                    Jun 26 '17 at 17:54













                  • Link is now fixed on the server (server had an incorrectly configured timezone causing it to serve the blog post at the wrong date).

                    – James Roper
                    Jun 27 '17 at 13:47














                  • 1





                    Why just making an HTTP request on a non standard port it is said to "open" the browser to being an open proxy to attack services in local network? Open how??

                    – jj_
                    Jul 22 '16 at 19:59











                  • If it is left unchecked then any malicious code can make request to URLs with arbitrary ports. It might not be an optimal solution but by blocking other ports you are only leaving attackers with 80 & 443 to exploit.

                    – Willa
                    Jan 23 '17 at 14:39











                  • the referenced link is now dead

                    – Jeff Puckett
                    Jun 13 '17 at 15:41











                  • Link is now dead. Wayback Machine: web.archive.org/web/20170216040700/https://jazzy.id.au/2012/08/… (suggested edit)

                    – Nulano
                    Jun 26 '17 at 17:54













                  • Link is now fixed on the server (server had an incorrectly configured timezone causing it to serve the blog post at the wrong date).

                    – James Roper
                    Jun 27 '17 at 13:47








                  1




                  1





                  Why just making an HTTP request on a non standard port it is said to "open" the browser to being an open proxy to attack services in local network? Open how??

                  – jj_
                  Jul 22 '16 at 19:59





                  Why just making an HTTP request on a non standard port it is said to "open" the browser to being an open proxy to attack services in local network? Open how??

                  – jj_
                  Jul 22 '16 at 19:59













                  If it is left unchecked then any malicious code can make request to URLs with arbitrary ports. It might not be an optimal solution but by blocking other ports you are only leaving attackers with 80 & 443 to exploit.

                  – Willa
                  Jan 23 '17 at 14:39





                  If it is left unchecked then any malicious code can make request to URLs with arbitrary ports. It might not be an optimal solution but by blocking other ports you are only leaving attackers with 80 & 443 to exploit.

                  – Willa
                  Jan 23 '17 at 14:39













                  the referenced link is now dead

                  – Jeff Puckett
                  Jun 13 '17 at 15:41





                  the referenced link is now dead

                  – Jeff Puckett
                  Jun 13 '17 at 15:41













                  Link is now dead. Wayback Machine: web.archive.org/web/20170216040700/https://jazzy.id.au/2012/08/… (suggested edit)

                  – Nulano
                  Jun 26 '17 at 17:54







                  Link is now dead. Wayback Machine: web.archive.org/web/20170216040700/https://jazzy.id.au/2012/08/… (suggested edit)

                  – Nulano
                  Jun 26 '17 at 17:54















                  Link is now fixed on the server (server had an incorrectly configured timezone causing it to serve the blog post at the wrong date).

                  – James Roper
                  Jun 27 '17 at 13:47





                  Link is now fixed on the server (server had an incorrectly configured timezone causing it to serve the blog post at the wrong date).

                  – James Roper
                  Jun 27 '17 at 13:47











                  7














                  On Mac you can create an app launching Chrome with parameters mentioned in other answers using Automator built-in Apple application:




                  1. Launch Automator


                  2. As "Type of document" choose "Application"


                  3. Add action "Run shell script"


                  4. Replace placeholder cat script in this action with:



                  /Applications/Google Chrome.app/Contents/MacOS/Google Chrome --explicitly-allowed-ports=5000,6000,7000




                  1. Save the created app as something like "Google Chrome with allowed unsafe ports" in your Application folder


                  2. Use this new app instead of Google Chrome directly


                  3. (optional) Replace default icon of the created "app" - Automator's robot - with Chrome's using this method (note: upvote that answer if you like it!)



                  Source: http://cubewot.de/node/266



                  image






                  share|improve this answer


























                  • This picture does not have the full path. It is automating the execution of a directory.

                    – ojblass
                    Sep 19 '18 at 4:27
















                  7














                  On Mac you can create an app launching Chrome with parameters mentioned in other answers using Automator built-in Apple application:




                  1. Launch Automator


                  2. As "Type of document" choose "Application"


                  3. Add action "Run shell script"


                  4. Replace placeholder cat script in this action with:



                  /Applications/Google Chrome.app/Contents/MacOS/Google Chrome --explicitly-allowed-ports=5000,6000,7000




                  1. Save the created app as something like "Google Chrome with allowed unsafe ports" in your Application folder


                  2. Use this new app instead of Google Chrome directly


                  3. (optional) Replace default icon of the created "app" - Automator's robot - with Chrome's using this method (note: upvote that answer if you like it!)



                  Source: http://cubewot.de/node/266



                  image






                  share|improve this answer


























                  • This picture does not have the full path. It is automating the execution of a directory.

                    – ojblass
                    Sep 19 '18 at 4:27














                  7












                  7








                  7







                  On Mac you can create an app launching Chrome with parameters mentioned in other answers using Automator built-in Apple application:




                  1. Launch Automator


                  2. As "Type of document" choose "Application"


                  3. Add action "Run shell script"


                  4. Replace placeholder cat script in this action with:



                  /Applications/Google Chrome.app/Contents/MacOS/Google Chrome --explicitly-allowed-ports=5000,6000,7000




                  1. Save the created app as something like "Google Chrome with allowed unsafe ports" in your Application folder


                  2. Use this new app instead of Google Chrome directly


                  3. (optional) Replace default icon of the created "app" - Automator's robot - with Chrome's using this method (note: upvote that answer if you like it!)



                  Source: http://cubewot.de/node/266



                  image






                  share|improve this answer















                  On Mac you can create an app launching Chrome with parameters mentioned in other answers using Automator built-in Apple application:




                  1. Launch Automator


                  2. As "Type of document" choose "Application"


                  3. Add action "Run shell script"


                  4. Replace placeholder cat script in this action with:



                  /Applications/Google Chrome.app/Contents/MacOS/Google Chrome --explicitly-allowed-ports=5000,6000,7000




                  1. Save the created app as something like "Google Chrome with allowed unsafe ports" in your Application folder


                  2. Use this new app instead of Google Chrome directly


                  3. (optional) Replace default icon of the created "app" - Automator's robot - with Chrome's using this method (note: upvote that answer if you like it!)



                  Source: http://cubewot.de/node/266



                  image







                  share|improve this answer














                  share|improve this answer



                  share|improve this answer








                  edited Apr 13 '17 at 12:45









                  Community

                  1




                  1










                  answered Apr 14 '16 at 10:26









                  GeorgeGeorge

                  17015




                  17015













                  • This picture does not have the full path. It is automating the execution of a directory.

                    – ojblass
                    Sep 19 '18 at 4:27



















                  • This picture does not have the full path. It is automating the execution of a directory.

                    – ojblass
                    Sep 19 '18 at 4:27

















                  This picture does not have the full path. It is automating the execution of a directory.

                  – ojblass
                  Sep 19 '18 at 4:27





                  This picture does not have the full path. It is automating the execution of a directory.

                  – ojblass
                  Sep 19 '18 at 4:27











                  4














                  For Mac:



                  /Applications/Google Chrome.app/Contents/MacOS/Google Chrome --explicitly-allowed-ports=5000,6000,7000


                  for ports 5000, 6000, and 7000.






                  share|improve this answer




























                    4














                    For Mac:



                    /Applications/Google Chrome.app/Contents/MacOS/Google Chrome --explicitly-allowed-ports=5000,6000,7000


                    for ports 5000, 6000, and 7000.






                    share|improve this answer


























                      4












                      4








                      4







                      For Mac:



                      /Applications/Google Chrome.app/Contents/MacOS/Google Chrome --explicitly-allowed-ports=5000,6000,7000


                      for ports 5000, 6000, and 7000.






                      share|improve this answer













                      For Mac:



                      /Applications/Google Chrome.app/Contents/MacOS/Google Chrome --explicitly-allowed-ports=5000,6000,7000


                      for ports 5000, 6000, and 7000.







                      share|improve this answer












                      share|improve this answer



                      share|improve this answer










                      answered Aug 21 '15 at 16:19









                      JayJay

                      1413




                      1413























                          3














                          As subanki said, you've got to add the -explicitly-allowed-ports option to your Chrome startup command.



                          In Ubuntu you can do this (as root) by editing the "google-chrome" script under your Chrome installation folder



                          You can get the directory by typing:



                          ls -la /usr/bin | grep chrome


                          Then, edit the "google-chrome" file adding the mentioned switch to the EXEC line:



                          exec -a "$0" "$HERE/chrome" "-explicitly-allowed-ports=6000" "$@"


                          Just change "6000" with the comma separated values you might need (example: -explicitly-allowed-ports=5000,6000,7000)



                          NOTE: for UNIX, the switch does NOT start with "--", it does with a single "-"






                          share|improve this answer






























                            3














                            As subanki said, you've got to add the -explicitly-allowed-ports option to your Chrome startup command.



                            In Ubuntu you can do this (as root) by editing the "google-chrome" script under your Chrome installation folder



                            You can get the directory by typing:



                            ls -la /usr/bin | grep chrome


                            Then, edit the "google-chrome" file adding the mentioned switch to the EXEC line:



                            exec -a "$0" "$HERE/chrome" "-explicitly-allowed-ports=6000" "$@"


                            Just change "6000" with the comma separated values you might need (example: -explicitly-allowed-ports=5000,6000,7000)



                            NOTE: for UNIX, the switch does NOT start with "--", it does with a single "-"






                            share|improve this answer




























                              3












                              3








                              3







                              As subanki said, you've got to add the -explicitly-allowed-ports option to your Chrome startup command.



                              In Ubuntu you can do this (as root) by editing the "google-chrome" script under your Chrome installation folder



                              You can get the directory by typing:



                              ls -la /usr/bin | grep chrome


                              Then, edit the "google-chrome" file adding the mentioned switch to the EXEC line:



                              exec -a "$0" "$HERE/chrome" "-explicitly-allowed-ports=6000" "$@"


                              Just change "6000" with the comma separated values you might need (example: -explicitly-allowed-ports=5000,6000,7000)



                              NOTE: for UNIX, the switch does NOT start with "--", it does with a single "-"






                              share|improve this answer















                              As subanki said, you've got to add the -explicitly-allowed-ports option to your Chrome startup command.



                              In Ubuntu you can do this (as root) by editing the "google-chrome" script under your Chrome installation folder



                              You can get the directory by typing:



                              ls -la /usr/bin | grep chrome


                              Then, edit the "google-chrome" file adding the mentioned switch to the EXEC line:



                              exec -a "$0" "$HERE/chrome" "-explicitly-allowed-ports=6000" "$@"


                              Just change "6000" with the comma separated values you might need (example: -explicitly-allowed-ports=5000,6000,7000)



                              NOTE: for UNIX, the switch does NOT start with "--", it does with a single "-"







                              share|improve this answer














                              share|improve this answer



                              share|improve this answer








                              edited Jan 7 '14 at 9:16









                              Andrea

                              1,43631316




                              1,43631316










                              answered Jan 7 '14 at 7:57









                              SpinoSpino

                              311




                              311























                                  0














                                  Here is the correct answer for those of you who are developers using node.js as a web server

                                  Change the port you are using to host your web pages.

                                  For example

                                  if you typed into command line node index.js & pressed enter,

                                  if it started running on port 22 for 80 http request,

                                  when you visit the website at port 22,

                                  the chrome browser with throw this error page.,br>
                                  keyword UNSAFE PORT means port needs to match the content.

                                  Thank you.






                                  share|improve this answer




























                                    0














                                    Here is the correct answer for those of you who are developers using node.js as a web server

                                    Change the port you are using to host your web pages.

                                    For example

                                    if you typed into command line node index.js & pressed enter,

                                    if it started running on port 22 for 80 http request,

                                    when you visit the website at port 22,

                                    the chrome browser with throw this error page.,br>
                                    keyword UNSAFE PORT means port needs to match the content.

                                    Thank you.






                                    share|improve this answer


























                                      0












                                      0








                                      0







                                      Here is the correct answer for those of you who are developers using node.js as a web server

                                      Change the port you are using to host your web pages.

                                      For example

                                      if you typed into command line node index.js & pressed enter,

                                      if it started running on port 22 for 80 http request,

                                      when you visit the website at port 22,

                                      the chrome browser with throw this error page.,br>
                                      keyword UNSAFE PORT means port needs to match the content.

                                      Thank you.






                                      share|improve this answer













                                      Here is the correct answer for those of you who are developers using node.js as a web server

                                      Change the port you are using to host your web pages.

                                      For example

                                      if you typed into command line node index.js & pressed enter,

                                      if it started running on port 22 for 80 http request,

                                      when you visit the website at port 22,

                                      the chrome browser with throw this error page.,br>
                                      keyword UNSAFE PORT means port needs to match the content.

                                      Thank you.







                                      share|improve this answer












                                      share|improve this answer



                                      share|improve this answer










                                      answered Mar 7 '18 at 22:27









                                      jehovahsaysjehovahsays

                                      1186




                                      1186























                                          0














                                          I still get error



                                          http://localhost:6000/upload net::ERR_UNSAFE_PORT


                                          after starting chrome using automator...any ideas why?





                                          share








                                          New contributor




                                          Lucas Franco is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                          Check out our Code of Conduct.

























                                            0














                                            I still get error



                                            http://localhost:6000/upload net::ERR_UNSAFE_PORT


                                            after starting chrome using automator...any ideas why?





                                            share








                                            New contributor




                                            Lucas Franco is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                            Check out our Code of Conduct.























                                              0












                                              0








                                              0







                                              I still get error



                                              http://localhost:6000/upload net::ERR_UNSAFE_PORT


                                              after starting chrome using automator...any ideas why?





                                              share








                                              New contributor




                                              Lucas Franco is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                              Check out our Code of Conduct.










                                              I still get error



                                              http://localhost:6000/upload net::ERR_UNSAFE_PORT


                                              after starting chrome using automator...any ideas why?






                                              share








                                              New contributor




                                              Lucas Franco is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                              Check out our Code of Conduct.








                                              share


                                              share






                                              New contributor




                                              Lucas Franco is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                              Check out our Code of Conduct.









                                              answered 5 mins ago









                                              Lucas FrancoLucas Franco

                                              1




                                              1




                                              New contributor




                                              Lucas Franco is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                              Check out our Code of Conduct.





                                              New contributor





                                              Lucas Franco is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                              Check out our Code of Conduct.






                                              Lucas Franco is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                              Check out our Code of Conduct.






























                                                  draft saved

                                                  draft discarded




















































                                                  Thanks for contributing an answer to Super User!


                                                  • Please be sure to answer the question. Provide details and share your research!

                                                  But avoid



                                                  • Asking for help, clarification, or responding to other answers.

                                                  • Making statements based on opinion; back them up with references or personal experience.


                                                  To learn more, see our tips on writing great answers.




                                                  draft saved


                                                  draft discarded














                                                  StackExchange.ready(
                                                  function () {
                                                  StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f188006%2fhow-to-fix-err-unsafe-port-error-on-chrome-when-browsing-to-unsafe-ports%23new-answer', 'question_page');
                                                  }
                                                  );

                                                  Post as a guest















                                                  Required, but never shown





















































                                                  Required, but never shown














                                                  Required, but never shown












                                                  Required, but never shown







                                                  Required, but never shown

































                                                  Required, but never shown














                                                  Required, but never shown












                                                  Required, but never shown







                                                  Required, but never shown







                                                  Popular posts from this blog

                                                  Cannot install PyQt5 The Next CEO of Stack OverflowCannot install tcpreplay 3.4.4cannot...

                                                  Kapp-Putsch Acontecimentos | Outros artigos | Menu de navegação

                                                  Why did early computer designers eschew integers? The Next CEO of Stack OverflowWhat register...