initial commit of shared functionality