Пример #1
0
 /**
  * Authorize Security Group Ingress 
  * The AuthorizeSecurityGroupIngress operation adds permissions to a security
  * group.
  * Permissions are specified by the IP protocol (TCP, UDP or ICMP), the source of
  * the request (by IP range or an Amazon EC2 user-group pair), the source and
  * destination port ranges (for TCP and UDP), and the ICMP codes and types (for
  * ICMP). When authorizing ICMP, -1 can be used as a wildcard in the type and code
  * fields.
  * Permission changes are propagated to instances within the security group as
  * quickly as possible. However, depending on the number of instances, a small
  * delay might occur.
  * When authorizing a user/group pair permission, GroupName,
  * SourceSecurityGroupName and SourceSecurityGroupOwnerId must be specified. When
  * authorizing a CIDR IP permission, GroupName, IpProtocol, FromPort, ToPort and
  * CidrIp must be specified. Mixing these two types of parameters is not allowed.
  * 
  * @see http://docs.amazonwebservices.com/AWSEC2/2008-12-01/DeveloperGuide/ApiReference-Query-AuthorizeSecurityGroupIngress.html
  * @param mixed $request array of parameters for Amazon_EC2_Model_AuthorizeSecurityGroupIngressRequest request
  * or Amazon_EC2_Model_AuthorizeSecurityGroupIngressRequest object itself
  * @see Amazon_EC2_Model_AuthorizeSecurityGroupIngress
  * @return Amazon_EC2_Model_AuthorizeSecurityGroupIngressResponse Amazon_EC2_Model_AuthorizeSecurityGroupIngressResponse
  *
  * @throws Amazon_EC2_Exception
  */
 public function authorizeSecurityGroupIngress($request)
 {
     if (!$request instanceof Amazon_EC2_Model_AuthorizeSecurityGroupIngressRequest) {
         require_once 'Amazon/EC2/Model/AuthorizeSecurityGroupIngressRequest.php';
         $request = new Amazon_EC2_Model_AuthorizeSecurityGroupIngressRequest($request);
     }
     require_once 'Amazon/EC2/Model/AuthorizeSecurityGroupIngressResponse.php';
     return Amazon_EC2_Model_AuthorizeSecurityGroupIngressResponse::fromXML($this->_invoke($this->_convertAuthorizeSecurityGroupIngress($request)));
 }
Пример #2
0
 /**
  * Authorize Security Group Ingress 
  * The AuthorizeSecurityGroupIngress operation adds permissions to a security
  * group.
  * Permissions are specified by the IP protocol (TCP, UDP or ICMP), the source of
  * the request (by IP range or an Amazon EC2 user-group pair), the source and
  * destination port ranges (for TCP and UDP), and the ICMP codes and types (for
  * ICMP). When authorizing ICMP, -1 can be used as a wildcard in the type and code
  * fields.
  * Permission changes are propagated to instances within the security group as
  * quickly as possible. However, depending on the number of instances, a small
  * delay might occur.
  * When authorizing a user/group pair permission, GroupName,
  * SourceSecurityGroupName and SourceSecurityGroupOwnerId must be specified. When
  * authorizing a CIDR IP permission, GroupName, IpProtocol, FromPort, ToPort and
  * CidrIp must be specified. Mixing these two types of parameters is not allowed.
  *   
  * @see http://docs.amazonwebservices.com/AWSEC2/2008-12-01/DeveloperGuide/ApiReference-Query-AuthorizeSecurityGroupIngress.html      
  * @param mixed $request array of parameters for Amazon_EC2_Model_AuthorizeSecurityGroupIngress request or Amazon_EC2_Model_AuthorizeSecurityGroupIngress object itself
  * @see Amazon_EC2_Model_AuthorizeSecurityGroupIngress
  * @return Amazon_EC2_Model_AuthorizeSecurityGroupIngressResponse Amazon_EC2_Model_AuthorizeSecurityGroupIngressResponse
  *
  * @throws Amazon_EC2_Exception
  */
 public function authorizeSecurityGroupIngress($request)
 {
     require_once 'Amazon/EC2/Model/AuthorizeSecurityGroupIngressResponse.php';
     return Amazon_EC2_Model_AuthorizeSecurityGroupIngressResponse::fromXML($this->_invoke('AuthorizeSecurityGroupIngress'));
 }