Consent is key in any sexual encounter. If both parties are fully aware of the situation and enthusiastically consent to it, then it can be okay. However, it's important to continually check in with each other and make sure everyone is on the same page.