1.) If an enemy is attacking you from across the borders of another civ, then that means that your enemy civ has probably signed a Right of Passage Agreement with that civ.
2.) What kind of peace settlement you can demand from an enemy civ you're at war with is contigent on how badly you're beating them. I've had cases where I was kicking the snot out of a civ, greatly depleting their military strength in the process, and was, therefore, able to demand and receive several cities from that civ. At that point, they'll do anything to placate you.
If you're at war with a civ that you haven't been able to damage very much, don't expect anything more than the peace agreement itself for your trouble.
Again, hope this helps