- Posts: 129
- Thank you received: 0
Support for SermonSpeaker 5.x is in bugfix mode only, the same as it is for Joomla 3.10.
I will not add any new features to this releases.
Please upgrade to SermonSpeaker 6.x and Joomla 4.x, which is better anyway.
I will not add any new features to this releases.
Please upgrade to SermonSpeaker 6.x and Joomla 4.x, which is better anyway.
Prohibit downloading unpublished sermons
21 Sep 2016 07:57 #6272
by Ken Lee
Prohibit downloading unpublished sermons was created by Ken Lee
Dear Thomas,
I find someone is leeching my audios by exploiting the serially numbered sermons. They go:
http://mysite/menuitem/download/audio/101-
http://mysite/menuitem/download/audio/102-
http://mysite/menuitem/download/audio/103-
And they could download audios that are not yet published.
I see relevant code is at:
github.com/Bakual/SermonSpeaker/blob/216...roller.php#L137-L144
It does not check sermon's publishing status.
I appended this to the query to limit the search result to those I want the public to access:
$query = $query . " AND state = 1 AND UTC_TIMESTAMP > publish_up";
$query = $query . " AND (publish_down = '0000-00-00 00:00:00' OR UTC_TIMESTAMP < publish_down)";
Do you think it is good?
Best Regards,
Ken
I find someone is leeching my audios by exploiting the serially numbered sermons. They go:
http://mysite/menuitem/download/audio/101-
http://mysite/menuitem/download/audio/102-
http://mysite/menuitem/download/audio/103-
And they could download audios that are not yet published.
I see relevant code is at:
github.com/Bakual/SermonSpeaker/blob/216...roller.php#L137-L144
It does not check sermon's publishing status.
I appended this to the query to limit the search result to those I want the public to access:
$query = $query . " AND state = 1 AND UTC_TIMESTAMP > publish_up";
$query = $query . " AND (publish_down = '0000-00-00 00:00:00' OR UTC_TIMESTAMP < publish_down)";
Do you think it is good?
Best Regards,
Ken
Please Log in or Create an account to join the conversation.
- Thomas Hunziker
-
- Offline
- Administrator
-
21 Sep 2016 15:01 #6274
by Thomas Hunziker
Replied by Thomas Hunziker on topic Prohibit downloading unpublished sermons
Yep, that should work.
I can have a look at including a similar check in future version.
I can have a look at including a similar check in future version.
Please Log in or Create an account to join the conversation.
- Thomas Hunziker
-
- Offline
- Administrator
-
21 Sep 2016 16:22 #6276
by Thomas Hunziker
Replied by Thomas Hunziker on topic Prohibit downloading unpublished sermons
I've fixed it with this commit:
github.com/Bakual/SermonSpeaker/commit/2...8c294d852527eda7ff4b
You can download the file here: raw.githubusercontent.com/Bakual/SermonS.../site/controller.php and replace yours with it.
You can download the file here: raw.githubusercontent.com/Bakual/SermonS.../site/controller.php and replace yours with it.
The following user(s) said Thank You: Ken Lee
Please Log in or Create an account to join the conversation.
Time to create page: 0.134 seconds