Results tagged “Patch”

In my previous post I offered a patch to Tiny Tiny RSS which made it possible to install and use Tiny Tiny RSS also on web servers which did not exactly meet the minimum requirements.

Today I managed to update and test the patch for the latest version of Tiny Tiny RSS, 1.7.9. This time the creation of the patch was much easier as large portions of the code have been changed in the meantime in a way which is compatible again with PHP 5.2, namely the usage of constants through instance variables has been removed in large parts of the code. But not everywhere.

Again, following things have been changed to make TT-RSS compatible to the older PHP version:

  • replace remaining constant-accesses via instances with static accesses
  • remove usages of namespaces (JShrink/MInify)
  • deactivate whole OTP (One Time Password) functionality, as this makes heavy usage of namespaces and I haven't been able to convert that completely

Like last time I offer a single patchfile which can be applied to Tiny Tiny RSS 1.7.9 or you can fetch the already patched installation files directly from the respective Github repository.

For installation just use the patched files instead of the original 1.7.9 files and follow the Tiny Tiny RSS installation guide as usual.

| | Comments (6)

Update 2013-05-31: I updated the patch to be compatible with Tiny Tiny RSS 1.7.9. See this posting for further info.

Last time I mentioned that I installed Tiny Tiny RSS on my server but had to make some changes so that it would run without error on this particular system. I wished I didn't have to patch it myself but I couldn't convince the hoster to update the server environment (which would also affect all other users on that system, yep the downside of shared hosting) and cause all sorts of follow-up trouble.

Luckily that's not a security issue as the installation is pretty locked down on all sides but it also adds additional issues for TT RSS which requires a bit more relaxed security settings.

Tiny Tiny RSS 1.7.8 has following issues with my environment:

  1. it requires PHP 5.3 but my environment only offers PHP 5.2
  2. it requires that the security restriction open_basedir is not active

TLDR: Download and apply this patch to your Tiny Tiny RSS 1.7.8 installation to enable PHP 5.2 and open_basedir compatibility.

Long explaination: To create compatibility with my environment I had to patch Tiny Tiny RSS in the following ways:

  • replace all instance-accesses to constants with static references (e.g. $pluginhost::HOOK_RENDER_ARTICLE_API -> PluginHost::HOOK_RENDER_ARTICLE_API)
  • remove uses of namespaces (e.g. JShrink\Minifier -> Minifier)
  • implement manual follow of a feed-redirection (HTTP/301,302), as curl can't auto-follow under restricted open_basedir environments
  • fix all checks on the environment versions and restrictions to the lower PHP version and stricter security

It took a few hours and some debugging but now I'm happy so far with a Tiny Tiny RSS installation which runs aparently without any issues. At least I haven't found any problems/issues since I finished that work.

Problems still may exist in following areas, which I could not or have not tested:

  • Multi-user/account support (I don't know if the constants are accessed through variable instances for a specific reason)
  • automatic feed-update (my server doesn't allow jobs), I'm using update-on-access

That's about it. In the meantime I found out that Tiny Tiny RSS released the next version 1.7.9. I'm trying to set up a github fork where I can follow the development better and support my compatibility patch for a longer time but I'm not that experienced with that process yet so it could take some time. I'll update this post when I'm finished with that.

Patchfile: TinyTinyRSS-1.7.8_PHP-5.2_compatibility.patch

|

1

Archives