Filtering category objects in a template?
You can do

{% set ids = myGlobal.liveCategories.ids() %}
{% set category = craft.categories.slug(craft.request.getSegment(3)).id(ids).first() %} 
{% if category %} 
    The category is valid 
{% else %} 
    No slug found, or the category is not in the list 
{% endif %} 


Explanation: you grab all the ids from your allowed categories and search for them in your query. If a category is found it is one of the allowed categories. If not the category is another one or the there is no element with a matching slug.