Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The notifications don't get triggered for Authentication Success/Failure #177

Closed
mancube opened this issue May 14, 2023 · 8 comments
Closed

Comments

@mancube
Copy link

mancube commented May 14, 2023

As said in the title, I've made Discord notifications when auth success/failure occurs, and they don't get triggered on that event.

@mancube
Copy link
Author

mancube commented May 14, 2023

In the Jellyfin log, nothing else related to the plugin appears besides this.

[18:56:49] [ERR] [3] Jellyfin.Server.Implementations.Users.UserManager: Error authenticating with provider Default

MediaBrowser.Controller.Authentication.AuthenticationException: Invalid username or password

   at Jellyfin.Server.Implementations.Users.DefaultAuthenticationProvider.Authenticate(String username, String password, User resolvedUser)

   at Jellyfin.Server.Implementations.Users.UserManager.AuthenticateWithProvider(IAuthenticationProvider provider, String username, String password, User resolvedUser)

[18:56:49] [INF] [3] Jellyfin.Server.Implementations.Users.UserManager: Authentication request for REDACTED has been denied (IP: REDACTED).

[18:56:49] [ERR] [3] Jellyfin.Server.Middleware.ExceptionMiddleware: Error processing request: Invalid username or password entered. URL POST /Users/authenticatebyname.

@TheAnachronism
Copy link

I'm currently having the same problem. Also goes for other types like Items Added.

@NilsLeo
Copy link

NilsLeo commented Feb 24, 2024

same here!

@frenzis01
Copy link

Any fix?

@Opa-
Copy link

Opa- commented Mar 26, 2024

Reporting the same issue.

Jellyfin Version: 10.8.13
Webhook 11.0.0.0

Auth success failures does appear in the logs

jellyfin  | [22:54:55] [INF] [11] Jellyfin.Api.Auth.CustomAuthenticationHandler: AuthenticationScheme: CustomAuthentication was challenged.
jellyfin  | [22:54:56] [ERR] [21] Jellyfin.Server.Implementations.Users.UserManager: Error authenticating with provider Default
jellyfin  | MediaBrowser.Controller.Authentication.AuthenticationException: Specified user does not exist.
...
jellyfin  | [22:55:50] [INF] [8] Jellyfin.Api.Auth.CustomAuthenticationHandler: AuthenticationScheme: CustomAuthentication was challenged.
jellyfin  | [22:55:51] [ERR] [10] Jellyfin.Server.Implementations.Users.UserManager: Error authenticating with provider Default
jellyfin  | MediaBrowser.Controller.Authentication.AuthenticationException: Invalid username or password
...
jellyfin  | [22:55:56] [INF] [11] Jellyfin.Api.Auth.CustomAuthenticationHandler: AuthenticationScheme: CustomAuthentication was challenged.
jellyfin  | [22:55:57] [INF] [11] Jellyfin.Server.Implementations.Users.UserManager: Authentication request for **** has succeeded.

@EL-R1
Copy link

EL-R1 commented Apr 6, 2024

same here

Jellyfin Version: 10.8.13
Webhook 11.0.0.0

[2024-04-06 15:38:27.799 +02:00] [INF] Authentication request for "user" has succeeded.
[2024-04-06 15:38:27.799 +02:00] [INF] Current/Max sessions for user "user": 4/4
[2024-04-06 15:38:27.799 +02:00] [ERR] Error processing request: "[XXX.XXX.XXX.XXX] User is at their maximum number of sessions". URL "POST" "/Users/authenticatebyname".
[2024-04-06 15:39:32.014 +02:00] [INF] "IntervalTrigger" fired for task: "Webhook Item Added Notifier"
[2024-04-06 15:39:32.014 +02:00] [INF] Queuing task "ItemAddedScheduledTask"
[2024-04-06 15:39:32.014 +02:00] [INF] Executing "Webhook Item Added Notifier"
[2024-04-06 15:39:32.014 +02:00] [INF] "Webhook Item Added Notifier" Completed after 0 minute(s) and 0 seconds
[2024-04-06 15:39:32.014 +02:00] [INF] ExecuteQueuedTasks

@HouseIndoril
Copy link

Same issue. I'm not terribly confident this is going to get any sort of love, considering its been in this state for nigh a year now. Which is a shame.

I have 2 existing notifications working for playback stop/start. Those worked perfect from the start, no extra messing with logging.json was required to get those to work, but I did modify my logging.json file according to the instructions to no effect.

Not really sure where to start with this one. I'm not terribly proficient with the templates so if there's a more fleshed out template I can use, that'd be great.

Here's my logging.json file.

    "Serilog": {
        "MinimumLevel": {
            "Default": "Information",
            "Override": {
                "Microsoft": "Warning",
                "System": "Warning",
                "Jellyfin.Plugin.Webhook": "Debug"
            }
        },
        "WriteTo": [
            {
                "Name": "Console",
                "Args": {
                    "outputTemplate": "[{Timestamp:HH:mm:ss}] [{Level:u3}] {Message:lj}{NewLine}{Exception}"
                }
            },
            {
                "Name": "Async",
                "Args": {
                    "configure": [
                        {
                            "Name": "File",
                            "Args": {
                                "path": "%JELLYFIN_LOG_DIR%//jellyfin.log",
                                "fileSizeLimitBytes": 10485700,
                                "rollOnFileSizeLimit": true,
                                "retainedFileCountLimit": 10,
                                "outputTemplate": "[{Timestamp:yyyy-MM-dd HH:mm:ss.fff zzz}] [{Level:u3}] {Message}{NewLine}{Exception}"
                            }
                        }
                    ]
                }
            }
        ]
    }
}

I can see failed login attempts in the jellyfin application logs but it seems the plugin is simply unaware of them.

[2024-04-07 11:49:33.934 -04:00] [ERR] Error authenticating with provider "Default"
MediaBrowser.Controller.Authentication.AuthenticationException: Specified user does not exist.
   at Jellyfin.Server.Implementations.Users.DefaultAuthenticationProvider.Authenticate(String username, String password, User resolvedUser)
   at Jellyfin.Server.Implementations.Users.UserManager.AuthenticateWithProvider(IAuthenticationProvider provider, String username, String password, User resolvedUser)
[2024-04-07 11:49:33.937 -04:00] [INF] Authentication request for "lalalala" has been denied (IP: "192.168.2.3").
[2024-04-07 11:49:33.938 -04:00] [ERR] Error processing request: "Invalid username or password entered". URL "POST" "/Users/authenticatebyname"

@crobibero
Copy link
Member

Fixed by jellyfin/jellyfin#8960

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants