mirror of
https://github.com/FreshRSS/FreshRSS.git
synced 2026-03-29 11:43:43 -04:00
Fix RSS and OPML access by token (#8434)
Regression from https://github.com/FreshRSS/FreshRSS/pull/8165 Follow-up of https://github.com/FreshRSS/FreshRSS/pull/8371
This commit is contained in:
committed by
GitHub
parent
7573fee4f0
commit
09aa9adb31
@@ -232,14 +232,14 @@ class FreshRSS_index_Controller extends FreshRSS_ActionController {
|
||||
|
||||
/**
|
||||
* This action displays the RSS feed of FreshRSS.
|
||||
* @deprecated See user query RSS sharing instead
|
||||
*/
|
||||
#[Deprecated('See user query RSS sharing instead')]
|
||||
public function rssAction(): void {
|
||||
$allow_anonymous = FreshRSS_Context::systemConf()->allow_anonymous;
|
||||
|
||||
// Check if user has access.
|
||||
if (!FreshRSS_Auth::hasAccess() && !$allow_anonymous) {
|
||||
Minz_Error::error(403);
|
||||
if (!FreshRSS_Auth::hasAccess() && !$allow_anonymous && !Minz_Request::tokenIsOk()) {
|
||||
Minz_Error::error(403, redirect: false);
|
||||
}
|
||||
|
||||
try {
|
||||
@@ -271,8 +271,8 @@ class FreshRSS_index_Controller extends FreshRSS_ActionController {
|
||||
$allow_anonymous = FreshRSS_Context::systemConf()->allow_anonymous;
|
||||
|
||||
// Check if user has access.
|
||||
if (!FreshRSS_Auth::hasAccess() && !$allow_anonymous) {
|
||||
Minz_Error::error(403);
|
||||
if (!FreshRSS_Auth::hasAccess() && !$allow_anonymous && !Minz_Request::tokenIsOk()) {
|
||||
Minz_Error::error(403, redirect: false);
|
||||
}
|
||||
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user