@staticmethod
def verify(R, message, signature, verbose=False):
    '\n        Input: the public keys R\n        |       the message\n        |       the signature computed with ringsign\n\n        Output: whether the message was signed by R or not\n        '
    g = UniqueRingSignature.g
    q = UniqueRingSignature.q
    h1 = UniqueRingSignature.h1
    h2 = UniqueRingSignature.h2
    parsed = signature.split(',')
    tt = int(parsed[2])
    cjs = list()
    tjs = list()
    for i in range(0, int(((len(parsed) / 2) - 1))):
        cjs.append(int(parsed[(3 + (2 * i))]))
        tjs.append(int(parsed[(4 + (2 * i))]))
    mR = list_to_string(R)
    val1 = (sum(cjs) % q)
    gyh1 = ''
    for i in range(len(tjs)):
        if (tjs[i] < 0):
            tjs[i] = ((q - 1) + tjs[i])
        if (cjs[i] < 0):
            cjs[i] = ((q - 1) + cjs[i])
        gy = ((pow(g, tjs[i], q) * pow(R[i], cjs[i], q)) % q)
        h = ((pow(int(h1((message + mR))), int(tjs[i])) * pow(tt, int(cjs[i]))) % q)
        gyh1 = ((gyh1 + str(gy)) + str(h))
    val2 = str(h2(((message + list_to_string(R)) + gyh1)))
    if (int(val1) == int(val2)):
        if (verbose == True):
            print('Signature is valid!\n')
            print(('Common Result: ' + str(val1)))
            print('---- Validation Completed ---- \n')
        return True
    else:
        if (verbose == True):
            print('Signature is not valid!\n')
            print(((str(val1) + ' != ') + str(val2)))
            print('---- Validation Completed ---- \n')
        return False
Input: the public keys R
|       the message
|       the signature computed with ringsign

Output: whether the message was signed by R or not
@staticmethod
def verify(R, message, signature, verbose=False):
    '\n        Input: the public keys R\n        |       the message\n        |       the signature computed with ringsign\n\n        Output: whether the message was signed by R or not\n        '
    g = UniqueRingSignature.g
    q = UniqueRingSignature.q
    h1 = UniqueRingSignature.h1
    h2 = UniqueRingSignature.h2
    parsed = signature.split(',')
    tt = int(parsed[2])
    cjs = list()
    tjs = list()
    for i in range(0, int(((len(parsed) / 2) - 1))):
        cjs.append(int(parsed[(3 + (2 * i))]))
        tjs.append(int(parsed[(4 + (2 * i))]))
    mR = list_to_string(R)
    val1 = (sum(cjs) % q)
    gyh1 = 
    for i in range(len(tjs)):
        if (tjs[i] < 0):
            tjs[i] = ((q - 1) + tjs[i])
        if (cjs[i] < 0):
            cjs[i] = ((q - 1) + cjs[i])
        gy = ((pow(g, tjs[i], q) * pow(R[i], cjs[i], q)) % q)
        h = ((pow(int(h1((message + mR))), int(tjs[i])) * pow(tt, int(cjs[i]))) % q)
        gyh1 = ((gyh1 + str(gy)) + str(h))
    val2 = str(h2(((message + list_to_string(R)) + gyh1)))
    if (int(val1) == int(val2)):
        if (verbose == True):
            print('Signature is valid!\n')
            print(('Common Result: ' + str(val1)))
            print('---- Validation Completed ---- \n')
        return True
    else:
        if (verbose == True):
            print('Signature is not valid!\n')
            print(((str(val1) + ' != ') + str(val2)))
            print('---- Validation Completed ---- \n')
        return False