Port of python library for shamirs secret sharing