Laravel 广播私人频道无法授权
我尝试建立广播系统
在使用公有频道时一切是正常的,使用私有频道时本地是正常的,推到线上时进行连接它会告知我无权访问,资源403
⚠ [11:04:35 AM] - D2CqXToZoUwGnrGlAXXx could not be authenticated to private-App.User.64
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>403 Forbidden</title>
</head><body>
<h1>Forbidden</h1>
<p>You don't have permission to access /broadcasting/auth
mon this server.</p>
</body></html>
Client can not be authenticated, got HTTP status 403
[11:04:35 AM] - Preparing authentication request to: https://localhost
[11:04:35 AM] - Sending auth request to: https://localhost/broadcasting/auth
我不清楚我的本地为什么能够通过访问,我没有更改过认证看守器,所以默认的AUTH是可用的
这是我的initEcho:
Provider:
routes:
可以看到上述都是默认配置,我并未做什么更改
我希望知道为何无法授权,或如何调试授权
问题解决: 检查apache访问日志发现授权访问一直被拒绝再次检查配置 问题原因:laravel-echo-server.json里的authHost配置为localhost 在HTTPS协议下APACHE配置vhosts-le-ssl.conf只配置了具体域名的访问请求权限 我将authHost改为vhosts-le-ssl.conf下的具体域名就可以成功访问