def revokeIp(): ec2.revoke_security_group(group_name=args.name, group_id=args.id, ip_protocol=args.ip_protocol, from_port=args.from_port, to_port=args.to_port, cidr_ip=args.cidr_ip)
def revoke_security_group(self, group_id, rule): ''' See `authorize_security_group` ''' ec2 = self.connect_ec2() kwargs = self._security_group_rule_to_kwargs(rule) kwargs['group_id'] = group_id ec2.revoke_security_group(**kwargs)
def revokeSource(): ec2.revoke_security_group( group_name=args.name, group_id=args.id, ip_protocol=args.ip_protocol, from_port=args.from_port, to_port=args.to_port, src_security_group_name=args.security_group_name, src_security_group_group_id=args.security_group_id)
def revoke_security_group(self, group_id, rule): """ See `authorize_security_group` """ ec2 = self.connect_ec2() kwargs = self._security_group_rule_to_kwargs(rule) kwargs['group_id'] = group_id try: ec2.revoke_security_group(**kwargs) except boto.exception.EC2ResponseError as e: raise RuleNotFoundException(e.error_message)
def revokeSource(): ec2.revoke_security_group(group_name=args.name, group_id=args.id, ip_protocol=args.ip_protocol, from_port=args.from_port, to_port=args.to_port, src_security_group_name=args.security_group_name, src_security_group_group_id=args.security_group_id)