A new vulnerability with iMessage has been disclosed which was patched in iOS 12.3 in May. You can find the report to detect outdated iPhones here: https://www.lansweeper.com/report/iphone-ios-12-3-imessage-vulnerability-audit/
Additionally, you can read more about the vulnerability here: https://www.lansweeper.com/vulnerability/imessage-vulnerability/
If you have any questions, issues or remarks, feel free leave a comment.