In ArcGis (from Basic-License on) you have the opportunity to select a "line"-output (ArcToolBox-Analysis-Overlay-Intersect) when intersecting 2 different polygon layers. (This is (for example) ...
Some results have been hidden because they may be inaccessible to you
Show inaccessible results