private static AsciiString validate(AsciiString name) {
        if (name.isEmpty()) {
            throw new IllegalArgumentException("malformed header name: <EMPTY>");
        }

        if (!Flags.validateHeaders()) {
            return name;
        }

        final int lastIndex;
        try {
            lastIndex = name.forEachByte(value -> {
                if (value > LAST_PROHIBITED_NAME_CHAR) {
                    // Definitely valid.
                    return true;
                }

                return !PROHIBITED_NAME_CHARS.get(value);
            });
        } catch (Exception e) {
            throw new Error(e);
        }

        if (lastIndex >= 0) {
            throw new IllegalArgumentException(malformedHeaderNameMessage(name));
        }

        return name;
    }
Returned the raw header name used when creating the specified {@link AsciiString} with
{@link #create(String)}.
core/src/main/java/com/linecorp/armeria/common/HttpHeaderNames.java