diff --git a/umbral/pre.py b/umbral/pre.py index 35604ac..dfa1acf 100644 --- a/umbral/pre.py +++ b/umbral/pre.py @@ -63,7 +63,7 @@ class Capsule(object): self._attached_cfrags = list() @classmethod - def get_size(cls, curve: ec.EllipticCurve=None): + def get_size(cls, curve: ec.EllipticCurve=None, activated=False): """ Returns the size (in bytes) of a Capsule given the curve. If no curve is provided, it will use the default curve. @@ -72,7 +72,10 @@ class Capsule(object): bn_size = CurveBN.get_size(curve) point_size = Point.get_size(curve) - return (bn_size * 1) + (point_size * 2) + if not activated: + return (bn_size * 1) + (point_size * 2) + else: + return (bn_size * 1) + (point_size * 5) class NotValid(ValueError): """