'Validate given security group property.
:param value:          the value to validate, as a string or unicode
:param property:       the property, either \'name\' or \'description\'
:param allowed:        the range of characters allowed'

def validate_property(self, value, property, allowed):

    try:
        val = value.strip()
    except AttributeError:
        msg = (_('Security    group    %s    is    not    a    string    or    unicode') % property)
        self.raise_invalid_property(msg)
    utils.check_string_length(val, name=property, min_length=1, max_length=255)
    if (allowed and (not re.match(allowed, val))):
        msg = (_("Value    (%(value)s)    for    parameter    Group%(property)s    is    invalid.    Content    limited    to    '%(allowed)s'.") % {'value': value, 'allowed': allowed, 'property': property.capitalize()})
        self.raise_invalid_property(msg)
