This, for example, would be disallowed by the vBulletin template system, as it contains a call to a 'forbidden' function: mysql_query.
<if condition="$my_variable = mysql_query('SELECT * FROM mytable')">
<!-- naughty naughty... -->
</if>
- in_array
- is_array
- is_numeric
- isset
- empty
- defined
- array
- can_moderate*
- can_moderate_calendar*
- exec_switch_bg*
- is_browser*
- is_member_of*
Note:
Functions marked * are custom functions defined by vBulletin itself. Each function name is a link that will take you to the documentation for that function. Use of these functions requires knowledge of PHP
<if condition="isset($my_variable) AND is_browser('ie')">
<!-- $my_variable is set and the browser is Internet Explorer -->
</if>

[code]<if condition="is_member_of($bbuserinfo, 6)">foo</if>[/code]
The first variable is the users userinfo (if the user surfing is meant, use $bbuserinfo), the second variable is the usergroup that member has to belong to, for the condition to return true.
Both primary and additional usergroups are searched.
Edit:
Some useful variables to use in a conditional to check against a user's permissions are:
$show['admincplink']
$show['modcplink']
$show['member']
$show['guest']