Thank you for posting this in Microsoft Q&A.
As I understand you want to block sign-in of shared mailbox via conditional access policy in Entra ID.
Yes, you can block the sign-in of shared mailbox using CA policy in Entra ID. You can follow below instructions.
- Login to Entra ID portal https://entra.microsoft.com/
- Use Global admin credentials to login.
- Go to Protection >> Conditional access
- Click on Policies >> New policy
- Name the new policy
- Under users section select users and groups and select the shared mailbox account.
- Under Target resources select "All cloud apps"
- Now go to Access controls >> Grant
- Under grant you can select Block access.
Let us know if you have any further questions on this
Please "Accept the answer" if the information helped you. This will help us and others in the community as well.