You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This keeps Paperclip secure-by-default, and will prevent people trying to mess
328
+
with your filesystem.
329
+
330
+
NOTE: Also starting at version 4.0.0, Paperclip has another validation that
331
+
cannot be turned off. This validation will prevent content type spoofing. That
332
+
is, uploading, say, a PHP document as part of the EXIF tags of a well-formed
333
+
JPEG. This check is limited to the media type (the first part of the MIME type,
334
+
so, 'text' in 'text/plain'). This will prevent HTML documents from being
335
+
uploaded as JPEGs, but will not prevent GIFs from being uploaded with a .jpg
336
+
extension. This validation will only add validation errors to the form. It will
337
+
not cause Errors to be raised.
338
+
305
339
Defaults
306
340
--------
307
341
Global defaults for all your paperclip attachments can be defined by changing the Paperclip::Attachment.default_options Hash, this can be useful for setting your default storage settings per example so you won't have to define them in every has_attached_file definition.
0 commit comments