tl;dr Handle this as a business problem as well as a personal problem.
Like many workplace issues, this calls for communication.
It seems you work for a vendor company. Can you approach your boss at your own company and ask for advice on this? If management in the customer company despises your company, that's a business problem as well as a personal ...
This type of attitude appears sometimes in (big) corporations where the flow of information is slow and poor. In other words, as organizations get bigger, the management can sometimes lose track of the impact that each specific project has. It also happens that the people responsible for a project don't really understand it themselves and make unrealistic ...
Firstly, stop working extra hours!
If you aren't getting paid for them and your work isn't appreciated don't run yourself into the ground for them.
Take that extra time you have now to polish your CV and look for something where you will be a valued asset rather than a code monkey chained to their machine
How can I be open for collaborations, while avoiding interference and keeping the lead?
The two here are not mutually exclusive, nor should they be. Good leaders will encourage any collaboration and input from elsewhere, so long as that is done in a respectful and sensible fashion.
Where this can easily often go wrong is if:
Alice doesn't really want to ...
I want to communicate this situation to my friend in the client company who is overall responsible for this project, without damaging
my company. I personally believe the project manager should either be
corrected or removed from the project
Let's assume you do talk to your friend.
What are you going to say?
The decision to go with technology ...
Ask yourself the following questions:
Is the decision endangering the health or life of people in a direct causal manner (not: will possible flaws in the other technology just make the project harder/more expensive)
Is the use of the technology directly contradicting rules imposed in a strongly regulated industry (e.g. airospace, automotive, pharmaceutical, ...
How is any of this unethical?
Your entire post is a "he said, she said" rant about vague and subjective opinions on what's the best technology for this project. Your question reads like a jealous, angry rant from an impetuous child who didn't get their way.
Take no action and move on from this.
Your question has two different aspects: The first one is a technical issue in software engineering, and the second one is related to workplace professionalism.
Choosing PHP over .NET is not something that necesserily mean compromise in security, performance and other quality factors. So, the main problem here is the lack of transparency ...
With all due respect, this isn't whistleblowing. This is just you trying to take revenge on your employer for a decision you don't like.
If you're not happy at your current employer, find another job. Professionally. Don't try and take everyone else down as you walk out the door, because that will not help anyone, including you.