[wp-trac] [WordPress Trac] #31767: insert_with_markers() is not atomic, leading to corrupted .htaccess updates under race conditions

WordPress Trac noreply at wordpress.org
Fri Jun 12 23:51:30 UTC 2015


#31767: insert_with_markers() is not atomic, leading to corrupted .htaccess updates
under race conditions
----------------------------+------------------------------
 Reporter:  tigertech       |       Owner:
     Type:  defect (bug)    |      Status:  new
 Priority:  normal          |   Milestone:  Awaiting Review
Component:  Filesystem API  |     Version:  4.1.1
 Severity:  normal          |  Resolution:
 Keywords:  has-patch       |     Focuses:
----------------------------+------------------------------

Comment (by tigertech):

 Using flock would help on installations where both the directory is not
 writable and NFS is not in use. I would expect the number of those to be
 pretty small, though.

 (I came back to this bug because my company had another .htaccess file
 corrupted because of this today. Roughly speaking, for every thousand
 sites we host, we're seeing about one of these corruptions per year. It
 usually affects sites that use WooCommerce, which tries to rewrite the
 .htaccess file fairly often. Since it's a data corruption bug, perhaps the
 severity should be increased?)

--
Ticket URL: <https://core.trac.wordpress.org/ticket/31767#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list