To be specific the main problem is that I want to detect if the caller ID of the incoming cal I get is real or spoofed? Most VoIP servers now allow their clients to use any caller ID they want. Also, before the caller hears the ring no authentication is made by the operator (for example, Vodafone or O2) to check if the caller ID is valid or spoofed.
I found something an Android app called CallerDec that has ability to check if the caller ID is valid only if the caller (not attacker) has also installed CallerDec by a verification call.
But it is not enough and it won't work if the real caller hasn't installed that app. Many banks now allow full access to someone's account by just verifying the caller ID of the caller and the debit or credit card number associated with that caller ID. I am sure they must be aware of caller ID spoofing and have some special process for identifying spoofing.
There is a proprietary service TrustID available for business users that guarantee to detect if a caller ID is spoofed or real but as it is closed source we can't know how it works.