No parent or guardian or other person who by instrument of writing surrenders or has heretofore surrendered the custody of a child to any children's aid society, or institution shall thereafter, contrary to the terms of such instruments, be entitled to the custody of or any control or authority over or any right to interfere with any such child, and these same conditions shall prevail where a child is or has been delivered to such children's aid society or institution by action of any proper court.
K.S.A. 38-306