int SetObjectId(int len, byte* output)
{
    int idx = 0;

    if (output)
        output[idx++] = ASN_OBJECT_ID;
    else
        idx++;
    idx += SetLength(len, output ? output + idx : NULL);

    return idx;
}
int SetObjectId(int len, byte* output)
{
    int idx = 0;

    if (output)
        output[idx++] = ASN_OBJECT_ID;
    else
        idx++;
    idx += SetLength(len, output ? output + idx : NULL);

    return idx;
}