public function firstValueOf(string $name): AttributeValue
    {
        $oid = AttributeType::attrNameToOID($name);
        foreach ($this->_rdns as $rdn) {
            $tvs = $rdn->allOf($oid);
            if (count($tvs) > 1) {
                throw new \RangeException("RDN with multiple $name attributes.");
            }
            if (1 == count($tvs)) {
                return $tvs[0]->value();
            }
        }
        throw new \RangeException("Attribute $name not found.");
    }