[ZendTo] 4.20-3 bug-fix release

Jules Jules at Zend.To
Tue Jan 31 10:48:31 GMT 2017


Peter,

Please can you try this patch for your /opt/zendto/lib/NSSDropoff.php 
file? It should just add a check for the existence of mb_strimwidth and 
bail out with a more sensible error if it's not installed:

---SNIP---
--- NSSDropoff.php    (revision 1061)
+++ NSSDropoff.php    (working copy)
@@ -1323,12 +1323,10 @@

      // Check the length of the note.
      // Don't reject it any more, just trim it if it's too long.
-    //$notelength = strlen($note);
+    if (! function_exists('mb_strimwidth')) {
+      return 'Admin: Install the PHP module/rpm "mbstring".';
+    }
      $maxlen = $this->_dropbox->maxnotelength();
-    //if ($notelength>$maxlen) {
-    //  return sprintf($smarty->getConfigVariable('ErrorNoteTooLong'),
-    //                 $notelength, $maxlen);
-    //}
      $note = mb_strimwidth($note, 0, $maxlen, '...');

      $confirmDelivery = ( @$_POST['confirmDelivery'] ? TRUE : FALSE );
---SNIP---

Thanks!
Jules.

On 31/01/2017 09:56, Der PCFreak wrote:
> Hi Jules,
>
> many thanks for your work!
>
> Today I tried an update (cloned virtual machine) to the latest version
> on my 3 year old installation.
> My OS is CentOS6 (it was one of the downloadable preconfigured vms that
> were available some day from zendto homepage) with all available updates
> applied.
>
> First of all it worked quite well but I want to share my findings to
> maybe help others.
>
> # yum update (I was updating from 4.12-5.noarch)
> worked but gave the following warnings:
>
> warning: /opt/zendto/config/preferences.php created as
> /opt/zendto/config/preferences.php.rpmnew
> warning: /opt/zendto/config/zendto.conf created as
> /opt/zendto/config/zendto.conf.rpmnew
> warning: /opt/zendto/templates/about.tpl created as
> /opt/zendto/templates/about.tpl.rpmnew
> warning: /opt/zendto/templates/login.tpl created as
> /opt/zendto/templates/login.tpl.rpmnew
> warning: /opt/zendto/templates/new_dropoff.tpl created as
> /opt/zendto/templates/new_dropoff.tpl.rpmnew
>
> warning:    erase unlink of
> /opt/zendto/templates_c/This.Dir.Must.Be.Writeable.By.Apache failed: No
> such file or directory
> warning:    erase unlink of /opt/zendto/templates_c failed: No such file
> or directory
> warning:    erase unlink of
> /opt/zendto/myzendto.templates_c/This.Dir.Must.Be.Writeable.By.Apache
> failed: No such file or directory
> warning:    erase unlink of /opt/zendto/myzendto.templates_c failed: No
> such file or directory
> warning:    erase unlink of
> /opt/zendto/cache/This.Dir.Must.Be.Writeable.By.Apache failed: No such
> file or directory
> warning:    erase unlink of /opt/zendto/cache failed: No such file or
> directory
>
> The ones about .rpmnew were normal and I diffed them all against my
> current configuration. It was a bit of work but no problem.
> One difference that came up was a missing "c" in line 57 of about.tpl.
> The only difference is this missing "c" (omputer -> computer) and this
> resulted in the .rpmnew. As far as I remember this typo was already in
> the previous releases. So if you could fix it, it might help all that
> already fixed the typo and all updaters will receive a corrected version.
>
> Another thing I changed (for security reasons) was in login.tpl
> I changed:
>         <td align="right"><b>Your password:</b></td>
>         <td><input type="password" id="passwordField" name="password"
> size="15" value=""/></td>
> to:
>         <td align="right"><b>Your Password:</b></td>
>         <td><input type="password" id="passwordField" name="password"
> size="15" value="" autocomplete="off"/></td>
>
> to avoid autocomplete for the password field. This is came up one day in
> the mailing list and for security reasons I thought I will disable
> autocomplete here.
>
> When trying the first dropoff I ran into the (known) error:
>       Fatal error: Call to undefined function mb_strimwidth() in
> /opt/zendto/lib/NSSDropoff.php on line 1332
> This could be easily fixed by installing "php-mbstring" and restarting
> Apache.
>
> All my custom commands like 'dropls' to show current dropoffs from the
> command line also worked as before.
>
> I am not sure about the "erase unlink ..." warnings, but it seems, that
> my clone works and I will test a little bit and the update the live
> system with the same changes.
>
> You mentioned that cleanup.php wasn't working in previous versions.
>
> Could you tell me how this daily job gets executed and how to verify it
> manually?
>
> Thanks in advance and thanks for the wonderful product you created and
> your continous work to keep it up to date.
>
> Kind regards
>
> Peter
>
> On 30.01.2017 11:19, Jules wrote:
>> Folks,
>>
>> I discovered from reports that cleanup.php wasn't working at all. It's
>> run nightly to delete old drop-offs that have expired, and to send
>> warning emails to recipients that their dropoff is about to be deleted,
>> if no one has picked it up.
>>
>> This is now fixed.
>>
>> I have also changed how the IMAP authenticator works, so it should now
>> behave a lot better with Exchange and Office365 IMAP services.
>>
>> 4.20-3 is on the website and in the repositories.
>> Just do a
>>        yum upgrade zendto
>> or
>>        sudo apt-get upgrade zendto
>> to install it. There should be no need to restart any services at all.
>>
>> Cheers,
>>
>> Jules
>>
> _______________________________________________
> ZendTo mailing list
> ZendTo at zend.to
> http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto

Jules

-- 
Julian Field MEng MBCS CITP CEng

'When I read Shakespeare I am struck with wonder
  That such trivial people should muse and thunder
  In such lovely language.' - D.H. Lawrence

www.Zend.To
Twitter: @JulesFM
PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654



More information about the ZendTo mailing list