Finds an attachment that matches {@link Attachment#name}, {@link Attachment#hash}, 
{@link Attachment#containerType} and {@link Attachment#containerId} with the given one.