You can check for missions with various cities of your faction. One of the random missions (while at war) is to end the war. You then need to defeat, bribe, or convince one specific lord from the opposing faction, and bribe or convince a specific lord from your own faction to settle the issue. Taking the opposing lord captive also works, and if your own faction's lord is taken captive by the enemy, he can't oppose your efforts to settle it.