Cropping a bezier path
I'm familiar with cropping shapes, but is there a way to crop a bezier path?
E.g. in the below screengrab I'd like to cut off the parts of the path that are outside the pink square. Currently the only way I can think of doing it would be to manually insert anchor points on the path that intersect with the square?

