Detection of encryption type of wifi network

Hello!

How can I detect encryption type (WPA2\WPA\Open) and cipher (CCM\TKIP) of wifi network that I wish connect the routeros to? Using only mikrotik router with routeros.

Yes, I can use my smartphone to connect to the network and then copy settings to routeros, but if I only have the router and network password, what can I do to set security-profile correctly?

Thank you.