Detect if a polygon collider2D is fully inside another polygon collider2D?

199761-x1.png

now I use raycast from each edge of star to next edge,then if all of them detect rectangle ,it means rectangle is inside star ,Is there an easier way to do this?

The easiest way I can think of off the top of my head would be rather than make the star a collider make the outside of the star the collider. Not sure if you can make one collider with a hole or if you need multiple colliders, picture to explain.