def get_init_flt():
 user = get_user()
 if (user in INIT_QUERIES):
  return INIT_QUERIES[user]
 if (isinstance(user, basestring) and ('@' in user)):
  realm = user[user.index('@'):]
  if (realm in INIT_QUERIES):
   return INIT_QUERIES[realm]
 if config.WEB_PUBLIC_SRV:
  return db.nmap.searchcategory(['Shared', get_anonymized_user()])
 return DEFAULT_INIT_QUERY

def get_init_flt ( ) : user = get_user ( ) if ( user in INIT_QUERIES ) : return INIT_QUERIES [ user ] if ( isinstance ( user , basestring ) and ( '@' in user ) ) : realm = user [ user . index ( '@' ) : ] if ( realm in INIT_QUERIES ) : return INIT_QUERIES [ realm ] if config . WEB_PUBLIC_SRV : return db . nmap . searchcategory ( [ 'Shared' , get_anonymized_user ( ) ] ) return DEFAULT_INIT_QUERY
return a filter corresponding to the current users privileges .