Lundi 26 Octobre 2026 03:31:12 GMT+01:00

Netcrook

AccueilManifeste
Actualités
Techcrook
Geocrook
WikicrookÉquipeAppContact
EnglishItaliano

WIKICROOK

Marshal.load

A Ruby method that deserializes data back into objects and should not be used on untrusted input.

Marshal.load is a Ruby deserialization method: it takes serialized bytes and rebuilds them into live Ruby objects. That convenience is useful for trusted storage, but it is dangerous when the input can be influenced by an attacker. Deserialization can trigger object constructors, callbacks, and other hooks that were never meant to process hostile data.

In cyber security, Marshal.load matters because unsafe deserialization is a common path to code execution. If an application loads untrusted data and the runtime has reachable gadget methods, an attacker may chain ordinary object behavior into an unintended action, including remote command execution. Defenses are straightforward: do not use Marshal.load on user-controlled data, prefer primitive formats such as JSON, and keep any binary object format inside a strict trust boundary with authentication and validation.

← index WIKICROOK