how to extract the username of the wordpress user?

This is what you are looking for:

http://codex.wordpress.org/Function_Reference/get_currentuserinfo

<?php global $user_identity; 
get_currentuserinfo(); 
?> 

The username will be stored in the global variable $user_identity. If you are adding capabilities (I assume this is what is meant by ‘special authorities’) then it would make more sense to use the $user_ID global variable.