Properties of bilayer contacts to porous silicon