  The paradigm that gamma-ray burst (GRB) fireballs are the sources of the
ultra-high energy cosmic rays (UHECRs) is being probed by neutrino
observations. Very stringent bounds can be obtained from the cosmic ray
(proton)--neutrino connection, assuming that the UHECRs escape as neutrons. In
this study, we identify three different regimes as a function of the fireball
parameters: the standard "one neutrino per cosmic ray" case, the optically
thick (to neutron escape) case, and the case where leakage of protons from the
boundaries of the shells (direct escape) dominates. In the optically thick
regime, photomeson production is very efficient, and more neutrinos will be
emitted per cosmic ray than in the standard case, whereas in the direct
escape-dominated regime, more cosmic rays than neutrinos will be emitted. We
demonstrate that, for efficient proton acceleration, which is required to
describe the observed UHECR spectrum, the standard case only applies to a very
narrow region of the fireball parameter space. We illustrate with several
observed examples that conclusions on the cosmic ray--neutrino connection will
depend on the actual burst parameters. We show that the definition of the pion
production efficiency currently used by the IceCube collaboration
underestimates the neutrino production in the optically thick case. Finally, we
point out that the direct escape component leads to a spectral break in the
cosmic ray spectrum emitted from a single source. The resulting "two-component
model" can be used to even more strongly pronounce the spectral features of the
observed UHECR spectrum than the dip model.
