Sometimes when one receives referee's reports, the referee supplies alternative proofs for the results of the paper. Sometimes the supplied proof is much shorter and more elegant than the original proof.
Is it acceptable to include these proofs in the paper (without formally asking the permission from the reviewer) if the author emphasizes that this proof comes from the anonymous reviewer?
Many times I have done this, and the reviewer has never objected. But I am wondering if one should be more cautious and first formally asks a permission and if the referee permits then includes the referee's proof.
If that matters the subject is Mathematics.
Edit: Side information (following the comment). Assuming that the supplied proofs are for the auxiliary results of the paper, not the main results.