def METHOD_NAME(self, secparam=1024):
    if group.p == 0 or group.q == 0:
        group.METHOD_NAME(secparam)
    g, x = group.randomGen(), group.random()    # g, [1,q-1]
    y = g ** x
    if debug:
        print("Public params")
        print("g =>", g); print("y =>", y)
    pk = {'g': g, 'y': y}
    sk = {'x': x}
    return pk, sk