unity-jar-resolver icon indicating copy to clipboard operation
unity-jar-resolver copied to clipboard

[Bug] Non-secure network connections disabled in Player Settings

Open Thaina opened this issue 3 years ago • 6 comments

[REQUIRED] Please fill in the following fields:

  • Unity editor version: 2022.1.0b1
  • External Dependency Manager version: 1.2.168
  • Source you installed EDM4U: UPM tgz
  • Features in External Dependency Manager in use: Android Resolver + VersionHandler
  • Plugins SDK in use: -
  • Platform you are using the Unity editor on: Windows

[REQUIRED] Please describe the issue here:

Weird error and warning while using EDM4U

image

It seem the config for using secure connection was needed to disabled to shut these error

Please answer the following, if applicable:

What's the issue repro rate? (eg 100%, 1/5 etc)

  • 100%

What happened? How can we make the problem occur?

  • Just install and open unity editor and also every action that trigger

I suspect that this below might be the cause?

https://github.com/googlesamples/unity-jar-resolver/blob/d370ab8ef6c9199ae8d033c9d75e8f727e8b0c3d/source/VersionHandlerImpl/src/EditorMeasurement.cs#L516-L517

Any reason using http here though?

Thaina avatar Dec 13 '21 17:12 Thaina

This issue does not seem to follow the issue template. Make sure you provide all the required information.

google-oss-bot avatar Dec 13 '21 17:12 google-oss-bot

Hi @Thaina,

In order to identify what's causing this, could you provide the complete steps needed to replicate the issue?

paulinon avatar Dec 14 '21 10:12 paulinon

@paulinon Just install 1.2.168 by tgz in 2022.1.0b1 android project then close and reopen project it will throw this error every time

I am not sure for your machine but I think default setting for Allow HTTP should be Not Allowed. So it should always cause this error unless it was set as anything but Not Allowed in your project

Thaina avatar Dec 14 '21 10:12 Thaina

@Thaina

Thank you for reporting this issue. Seems like Unity 2022 added some security feature which blocks the non-https web request. I wonder why it used http in the first place.

At the meantime, as a workaround, I would recommend you to disable Analytics reporting from our editor tools for now. Here are all the settings:

  • EDM4U: Assets > External Dependency Manager > Version Handler > Settings > Enable Analytics Reporting
  • Firebase: Windows > Firebase > Documentation > Enable Analytics Reporting (At the very bottom)

chkuang-g avatar Dec 14 '21 19:12 chkuang-g

I have followed the recommendation by @chkuang-g and it works well with Unity 2022.1.3f1.

However, in principle Unity is doing the right by blocking non-secure connections, so, please, someone should review the reason why this is using http instead of https, and upgrade it if possible.

FranArjona avatar Jun 02 '22 09:06 FranArjona

I am facing similar issues, apart from the workaround provided above, is there any progress on this issue?

devWithKD avatar Jul 07 '22 07:07 devWithKD