linuxserver / docker-sonarr

GNU General Public License v3.0
809 stars 141 forks source link

[BUG] Authentication required issue #283

Closed hendrix04 closed 7 months ago

hendrix04 commented 9 months ago

Is there an existing issue for this?

Current Behavior

I am being forced with a modal that says authentication is required and that I need to setup some authentication method.

When I try to add an authentication method, I get a 400 response saying that I need an SSL cert to continue

Expected Behavior

I shouldn't need need an SSL cert to set a password. I trust my internal network and I would like not not have deal with self signed certs or having to install other type of certs

Steps To Reproduce

Install sonarr from community services don't instal an SSL cert see that you can't do anything

Environment

- OS: Untraid
- How docker service was installed: Community services

CPU architecture

x86-64

Docker creation

unraid community app

Container logs

[Warn] SonarrErrorPipeline: Invalid request Validation failed: 
 -- SslCertPath: 'Ssl Cert Path' must not be empty.
github-actions[bot] commented 9 months ago

Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.

j0nnymoe commented 9 months ago

We don't set any sort of SSL cert requirement within sonarr. It sounds like you could have a previous install. Could you post the full container start up log please?

Also note, that sonarr itself is forcing users to put authentication on your install, again not something we do.

https://wiki.servarr.com/sonarr/faq-v4#forced-authentication

hendrix04 commented 9 months ago

`[migrations] started [migrations] no migrations found usermod: no changes ───────────────────────────────────────

  ██╗     ███████╗██╗ ██████╗
  ██║     ██╔════╝██║██╔═══██╗
  ██║     ███████╗██║██║   ██║
  ██║     ╚════██║██║██║   ██║
  ███████╗███████║██║╚██████╔╝
  ╚══════╝╚══════╝╚═╝ ╚═════╝

Brought to you by linuxserver.io ───────────────────────────────────────

To support the app dev(s) visit: Sonarr: https://sonarr.tv/donate

To support LSIO projects visit: https://www.linuxserver.io/donate/

─────────────────────────────────────── GID/UID ───────────────────────────────────────

User UID: 99 User GID: 100 ───────────────────────────────────────

[custom-init] No custom files found, skipping... [Info] Bootstrap: Starting Sonarr - /app/sonarr/bin/Sonarr - Version 4.0.0.748 [Info] AppFolderInfo: Data directory is being overridden to [/config] [Debug] Bootstrap: Console selected [Info] AppFolderInfo: Data directory is being overridden to [/config] [Info] AppFolderInfo: Data directory is being overridden to [/config] [Info] MigrationController: Migrating data source=/config/sonarr.db;cache size=-20000;datetimekind=Utc;journal mode=Wal;pooling=True;version=3;busytimeout=100 [Debug] MigrationController: Took: 00:00:00.1391471 [Debug] Microsoft.Extensions.Hosting.Internal.Host: Hosting starting [Info] MigrationController: Migrating data source=/config/logs.db;cache size=-20000;datetimekind=Utc;journal mode=Wal;pooling=True;version=3;busytimeout=100

[Info] Microsoft.Hosting.Lifetime: Application started. Press Ctrl+C to shut down. [Info] Microsoft.Hosting.Lifetime: Hosting environment: Production [Info] Microsoft.Hosting.Lifetime: Content root path: /app/sonarr/bin [Error] TaskExtensions: Task Error

[v4.0.0.748] System.NullReferenceException: Object reference not set to an instance of an object. at NzbDrone.Core.Configuration.ConfigFileProvider.SetValue(String key, Object value) in ./Sonarr.Core/Configuration/ConfigFileProvider.cs:line 307 at NzbDrone.Core.Configuration.ConfigFileProvider.<>cDisplayClass80_0.b0() in ./Sonarr.Core/Configuration/ConfigFileProvider.cs:line 297 at NzbDrone.Common.Cache.Cached1.Get(String key, Func1 function, Nullable`1 lifeTime) in ./Sonarr.Common/Cache/Cached.cs:line 98 at NzbDrone.Core.Configuration.ConfigFileProvider.GetValue(String key, Object defaultValue, Boolean persist) in ./Sonarr.Core/Configuration/ConfigFileProvider.cs:line 280 at NzbDrone.Core.Configuration.ConfigFileProvider.MigrateConfigFile() in ./Sonarr.Core/Configuration/ConfigFileProvider.cs:line 350 at NzbDrone.Core.Configuration.ConfigFileProvider.HandleAsync(ApplicationStartedEvent message) in ./Sonarr.Core/Configuration/ConfigFileProvider.cs:line 427 at NzbDrone.Core.Messaging.Events.EventAggregator.<>cDisplayClass6_2`1.b2() in ./Sonarr.Core/Messaging/Events/EventAggregator.cs:line 120 at System.Threading.Tasks.Task.InnerInvoke() at System.Threading.Tasks.Task.<>c.<.cctor>b__272_0(Object obj) at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state) --- End of stack trace from previous location --- at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.Tasks.Task.ExecuteWithThreadLocal(Task& currentTaskSlot, Thread threadPoolThread)

[ls.io-init] done. [Warn] SonarrErrorPipeline: Invalid request Validation failed: -- SslCertPath: 'Ssl Cert Path' must not be empty. [Info] RssSyncService: Starting RSS Sync [Info] DownloadDecisionMaker: Processing 150 releases [Info] RssSyncService: RSS Sync Completed. Reports found: 150, Reports grabbed: 0`

image

hendrix04 commented 9 months ago

BTW, I resolved this issue for my personal instance by editing my config xml. For some reason True was set (even though I have never used SSL on this server...

I have been using the Linux Server version of Sonarr for 2ish years (at least), though the container says it was created 5 years ago (perhaps due to an automatic update). My guess is that this update is what caused a weird configuration issue in some way.

LinuxServer-CI commented 8 months ago

This issue has been automatically marked as stale because it has not had recent activity. This might be due to missing feedback from OP. It will be closed if no further activity occurs. Thank you for your contributions.

zethis commented 7 months ago

Same issue here, if i set <AuthenticationMethod>External</AuthenticationMethod> like it's mentionned here, the config file repop everytime with two other lines added: <AuthenticationMethod>None</AuthenticationMethod> & <AuthenticationRequired>Enabled</AuthenticationRequired>

EDIT: Fixed by removed topmost value in the config.xml file that i don't see <AuthenticationRequired>Forms</AuthenticationRequired>

aptalca commented 7 months ago

I had a hard time with this as well. I believe the issue stems from having set a password for the gui a long time ago and later disabling auth. When the wizard shows up in the new versions that require auth, instead of letting you set a new password, it wants you to enter the old one you set ages ago. The password is in the sqlite db so you can't reset it through the config file.

When you modify the config file, make sure that there are no duplicate entries, delete all auth related entries, and then enter the following and restart:

  <AuthenticationRequired>Enabled</AuthenticationRequired>
  <AuthenticationMethod>External</AuthenticationMethod>

That should let you access the gui. Then you can go into gui settings and change things as needed.

With regards to the ssl certpath error, in my case it was a red herring. But to be sure, make sure the EnableSsl setting is set to False in the config file.

Closing as it's solved for op

github-actions[bot] commented 6 months ago

This issue is locked due to inactivity