[Tickets #9263] Re: Problems with serialized arrays stored in a MySQL DB

bugs at horde.org bugs at horde.org
Tue Oct 19 10:39:46 UTC 2010


BITTE NICHT AUF DIESE NACHRICHT ANTWORTEN. NACHRICHTEN AN DIESE  
E-MAIL-ADRESSE WERDEN NICHT GELESEN.

Ticket-URL: http://bugs.horde.org/ticket/9263
------------------------------------------------------------------------------
  Ticket           | 9263
  Aktualisiert Von | steffen.hau at rz.uni-mannheim.de
  Zusammenfassung  | Problems with serialized arrays stored in a MySQL DB
  Warteschlange    | Horde Base
  Version          | 3.3.8
  Typ              | Bug
  Status           | Not A Bug
  Priorität       | 1. Low
  Milestone        |
  Patch            |
  Zuständige      |
------------------------------------------------------------------------------


steffen.hau at rz.uni-mannheim.de (2010-10-19 06:39) hat geschrieben:

Dear Jan,

I've added something like
$string = preg_replace('!s:(\d+):"(.*?)";!se',  
"'s:'.strlen('$2').':\"$2\";'", $string);

before each occurence of unseralize in Horde's code. Now each  
serialized array gets correctly unserialized.

Wouldn't it be possible to add a helper function horde_unserialize as  
a wrapper for the php unserialize function which does sanitize the  
returned serialized arrays from the database tables? I'm wondering why  
no other people out there were running into this issue if they use  
opensuse.

Best regards,
Steffen






More information about the bugs mailing list