Ensure that Lambda Function is not publicly exposed via resource policy without a condition

Determine the specific resource-based principals' permissions needed by your Lambda Functions, and then craft a resource-based policy for these principals only.