cloudstack-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Min Chen (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (CLOUDSTACK-6613) IAM: authorizeSecurityGroupIngress fails when SG Name is passed.
Date Sat, 10 May 2014 22:15:15 GMT

     [ https://issues.apache.org/jira/browse/CLOUDSTACK-6613?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Min Chen resolved CLOUDSTACK-6613.
----------------------------------

    Resolution: Fixed

> IAM: authorizeSecurityGroupIngress fails when SG Name is passed.
> ----------------------------------------------------------------
>
>                 Key: CLOUDSTACK-6613
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-6613
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the default.) 
>          Components: API, IAM
>    Affects Versions: 4.4.0
>            Reporter: Parth Jagirdar
>            Assignee: Min Chen
>            Priority: Critical
>
> http://10.223.49.210:8080/client/api?command=authorizeSecurityGroupIngress&securityGroupName=root-sg&domainid=cf149abc-d640-11e3-98fe-ced18bec4952&account=admin&response=json&sessionkey=hazX8mXPD08rBk%2FkyQ2YIZkIYBE%3D
>  
> { "authorizesecuritygroupingressresponse" : {"uuidList":[],"errorcode":530,"cserrorcode":9999}
}
>  
>  
> There are no required param for this API:
>  
>  
> If I pass CIDR along with SGID; it works.
>  
>  
> If I pass CIDR along with SGName; it fails. Account and domain were passed(Exception
in below)
>  
>  
> So what is SGNAME and what it expects?
>  
> Also can this API’s designed such that they at least throw a relevant exception?
>  
>  
>  
> 2014-05-08 14:15:21,586 DEBUG [c.c.a.ApiServlet] (catalina-exec-25:ctx-e6705378) ===START===
 10.215.2.19 -- GET  command=authorizeSecurityGroupIngress&securityGroupName=root-sg&domainid=cf149abc-d640-11e3-98fe-ced18bec4952&account=admin&response=json&sessionkey=hazX8mXPD08rBk%2FkyQ2YIZkIYBE%3D
> 2014-05-08 14:15:21,598 ERROR [c.c.a.ApiServer] (catalina-exec-25:ctx-e6705378 ctx-145967d6)
unhandled exception executing api command: [Ljava.lang.String;@5c2c7824
> java.lang.NullPointerException
>         at com.cloud.api.dispatch.ParamProcessWorker.processParameters(ParamProcessWorker.java:159)
>         at com.cloud.api.dispatch.ParamProcessWorker.handle(ParamProcessWorker.java:93)
>         at com.cloud.api.dispatch.DispatchChain.dispatch(DispatchChain.java:37)
>         at com.cloud.api.ApiServer.queueCommand(ApiServer.java:620)
>         at com.cloud.api.ApiServer.handleRequest(ApiServer.java:502)
>         at com.cloud.api.ApiServlet.processRequestInContext(ApiServlet.java:330)
>         at com.cloud.api.ApiServlet.access$000(ApiServlet.java:54)
>         at com.cloud.api.ApiServlet$1.run(ApiServlet.java:118)
>         at org.apache.cloudstack.managed.context.impl.DefaultManagedContext$1.call(DefaultManagedContext.java:56)
>         at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.callWithContext(DefaultManagedContext.java:103)
>         at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.runWithContext(DefaultManagedContext.java:53)
>         at com.cloud.api.ApiServlet.processRequest(ApiServlet.java:115)
>         at com.cloud.api.ApiServlet.doGet(ApiServlet.java:77)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>         at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:555)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
>         at org.apache.coyote.http11.Http11NioProcessor.process(Http11NioProcessor.java:889)
>         at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:721)
>        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:2274)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>         at java.lang.Thread.run(Thread.java:744)
> 2014-05-08 14:15:21,606 DEBUG [c.c.u.AccountManagerImpl] (catalina-exec-25:ctx-e6705378
ctx-145967d6) Root Access granted to Acct[63f724e2-d641-11e3-98fe-ced18bec4952-admin] by RoleBasedEntityAccessChecker
> 2014-05-08 14:15:21,607 DEBUG [c.c.a.ApiServlet] (catalina-exec-25:ctx-e6705378 ctx-145967d6)
===END===  10.215.2.19 -- GET  command=authorizeSecurityGroupIngress&securityGroupName=root-sg&domainid=cf149abc-d640-11e3-98fe-ced18bec4952&account=admin&response=json&sessionkey=hazX8mXPD08rBk%2FkyQ2YIZkIYBE%3D
> 2014-05-08 14:15:22,052 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-12:null)
SeqA 2-12625: Processing Seq 2-12625:  { Cmd , MgmtId: -1, via: 2, Ver: v1, Flags: 11, [{"com.cloud.agent.api.ConsoleProxyLoadReportCommand":{"_proxyVmId":2,"_loadInfo":"{\n
 \"connections\": []\n}","wait":0}}] }
> 2014-05-08 14:15:22,059 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-12:null)
SeqA 2-12625: Sending Seq 2-12625:  { Ans: , MgmtId: 227399391005010, via: 2, Ver: v1, Flags:
100010, [{"com.cloud.agent.api.AgentControlAnswer":{"result":true,"wait":0}}] }
>  
>  
>  
>  
>  
> http://10.223.49.210:8080/client/api?command=authorizeSecurityGroupIngress&securityGroupName=root-sg&domainid=cf149abc-d640-11e3-98fe-ced18bec4952&account=admin&response=json&sessionkey=hazX8mXPD08rBk%2FkyQ2YIZkIYBE%3D
>  
>  
>  
> 2014-05-08 14:49:25,865 DEBUG [c.c.a.ApiServlet] (catalina-exec-22:ctx-1b32b973) ===START===
 10.215.2.19 -- GET  command=authorizeSecurityGroupIngress&securityGroupName=root-sg&domainid=cf149abc-d640-11e3-98fe-ced18bec4952&account=admin&response=json&sessionkey=hazX8mXPD08rBk%2FkyQ2YIZkIYBE%3D
> 2014-05-08 14:49:25,877 ERROR [c.c.a.ApiServer] (catalina-exec-22:ctx-1b32b973 ctx-9905e355)
unhandled exception executing api command: [Ljava.lang.String;@3d97846e
> java.lang.NullPointerException
>         at com.cloud.api.dispatch.ParamProcessWorker.processParameters(ParamProcessWorker.java:159)
>         at com.cloud.api.dispatch.ParamProcessWorker.handle(ParamProcessWorker.java:93)
>         at com.cloud.api.dispatch.DispatchChain.dispatch(DispatchChain.java:37)
>         at com.cloud.api.ApiServer.queueCommand(ApiServer.java:620)
>         at com.cloud.api.ApiServer.handleRequest(ApiServer.java:502)
>         at com.cloud.api.ApiServlet.processRequestInContext(ApiServlet.java:330)
>         at com.cloud.api.ApiServlet.access$000(ApiServlet.java:54)
>         at com.cloud.api.ApiServlet$1.run(ApiServlet.java:118)
>         at org.apache.cloudstack.managed.context.impl.DefaultManagedContext$1.call(DefaultManagedContext.java:56)
>         at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.callWithContext(DefaultManagedContext.java:103)
>         at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.runWithContext(DefaultManagedContext.java:53)
>         at com.cloud.api.ApiServlet.processRequest(ApiServlet.java:115)
>         at com.cloud.api.ApiServlet.doGet(ApiServlet.java:77)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>         at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:555)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
>         at org.apache.coyote.http11.Http11NioProcessor.process(Http11NioProcessor.java:889)
>         at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:721)
>         at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:2274)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>         at java.lang.Thread.run(Thread.java:744)
> 2014-05-08 14:49:25,885 DEBUG [c.c.u.AccountManagerImpl] (catalina-exec-22:ctx-1b32b973
ctx-9905e355) Root Access granted to Acct[63f724e2-d641-11e3-98fe-ced18bec4952-admin] by RoleBasedEntityAccessChecker
> 2014-05-08 14:49:25,886 DEBUG [c.c.a.ApiServlet] (catalina-exec-22:ctx-1b32b973 ctx-9905e355)
===END===  10.215.2.19 -- GET  command=authorizeSecurityGroupIngress&securityGroupName=root-sg&domainid=cf149abc-d640-11e3-98fe-ced18bec4952&account=admin&response=json&sessionkey=hazX8mXPD08rBk%2FkyQ2YIZkIYBE%3D
> 2014-05-08 14:49:27,393 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-10:null)
SeqA 2-12945: Processing Seq 2-12945:  { Cmd , MgmtId: -1, via: 2, Ver: v1, Flags: 11, [{"com.cloud.agent.api.ConsoleProxyLoadReportCommand":{"_proxyVmId":2,"_loadInfo":"{\n
 \"connections\": []\n}","wait":0}}] }
> 2014-05-08 14:49:27,399 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-10:null)
SeqA 2-12945: Sending Seq 2-12945:  { Ans: , MgmtId: 227399391005010, via: 2, Ver: v1, Flags:
100010, [{"com.cloud.agent.api.AgentControlAnswer":{"result":true,"wait":0}}] }
>  
>  
>  
>  
>  
> http://10.223.49.210:8080/client/api?command=authorizeSecurityGroupIngress&securityGroupName=root-sg&domainid=cf149abc-d640-11e3-98fe-ced18bec4952&account=admin&cidrlist=2.2.2.2/24&response=json&sessionkey=hazX8mXPD08rBk%2FkyQ2YIZkIYBE%3D
>  
>  
>  
> 2014-05-08 14:50:09,740 DEBUG [c.c.s.StatsCollector] (StatsCollector-1:ctx-2c843fe8)
HostStatsCollector is running...
> 2014-05-08 14:50:09,749 DEBUG [c.c.a.m.DirectAgentAttache] (DirectAgent-42:ctx-efbfd521)
Seq 1-8742331301656267308: Executing request
> 2014-05-08 14:50:09,825 DEBUG [c.c.a.m.DirectAgentAttache] (DirectAgent-42:ctx-efbfd521)
Seq 1-8742331301656267308: Response Received:
> 2014-05-08 14:50:09,826 DEBUG [c.c.a.t.Request] (StatsCollector-1:ctx-2c843fe8) Seq 1-8742331301656267308:
Received:  { Ans: , MgmtId: 227399391005010, via: 1, Ver: v1, Flags: 10, { GetHostStatsAnswer
} }
> 2014-05-08 14:50:09,889 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-15:null)
Ping from 2
> 2014-05-08 14:50:11,232 DEBUG [c.c.a.ApiServlet] (catalina-exec-7:ctx-77482e0f) ===START===
 10.215.2.19 -- GET  command=authorizeSecurityGroupIngress&securityGroupName=root-sg&domainid=cf149abc-d640-11e3-98fe-ced18bec4952&account=admin&cidrlist=2.2.2.2/24&response=json&sessionkey=hazX8mXPD08rBk%2FkyQ2YIZkIYBE%3D
> 2014-05-08 14:50:11,243 ERROR [c.c.a.ApiServer] (catalina-exec-7:ctx-77482e0f ctx-eb8ff5c1)
unhandled exception executing api command: [Ljava.lang.String;@4f3f5a06
> java.lang.NullPointerException
>         at com.cloud.api.dispatch.ParamProcessWorker.processParameters(ParamProcessWorker.java:159)
>         at com.cloud.api.dispatch.ParamProcessWorker.handle(ParamProcessWorker.java:93)
>         at com.cloud.api.dispatch.DispatchChain.dispatch(DispatchChain.java:37)
>         at com.cloud.api.ApiServer.queueCommand(ApiServer.java:620)
>         at com.cloud.api.ApiServer.handleRequest(ApiServer.java:502)
>         at com.cloud.api.ApiServlet.processRequestInContext(ApiServlet.java:330)
>         at com.cloud.api.ApiServlet.access$000(ApiServlet.java:54)
>         at com.cloud.api.ApiServlet$1.run(ApiServlet.java:118)
>         at org.apache.cloudstack.managed.context.impl.DefaultManagedContext$1.call(DefaultManagedContext.java:56)
>         at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.callWithContext(DefaultManagedContext.java:103)
>         at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.runWithContext(DefaultManagedContext.java:53)
>         at com.cloud.api.ApiServlet.processRequest(ApiServlet.java:115)
>         at com.cloud.api.ApiServlet.doGet(ApiServlet.java:77)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>         at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:555)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
>         at org.apache.coyote.http11.Http11NioProcessor.process(Http11NioProcessor.java:889)
>         at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:721)
>         at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:2274)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>         at java.lang.Thread.run(Thread.java:744)
> 2014-05-08 14:50:11,251 DEBUG [c.c.u.AccountManagerImpl] (catalina-exec-7:ctx-77482e0f
ctx-eb8ff5c1) Root Access granted to Acct[63f724e2-d641-11e3-98fe-ced18bec4952-admin] by RoleBasedEntityAccessChecker
> 2014-05-08 14:50:11,252 DEBUG [c.c.a.ApiServlet] (catalina-exec-7:ctx-77482e0f ctx-eb8ff5c1)
===END===  10.215.2.19 -- GET  command=authorizeSecurityGroupIngress&securityGroupName=root-sg&domainid=cf149abc-d640-11e3-98fe-ced18bec4952&account=admin&cidrlist=2.2.2.2/24&response=json&sessionkey=hazX8mXPD08rBk%2FkyQ2YIZkIYBE%3D
> 2014-05-08 14:50:11,663 DEBUG [c.c.s.StatsCollector] (StatsCollector-3:ctx-cc06edbb)
StorageCollector is running...
> 2014-05-08 14:50:11,739 DEBUG [c.c.a.t.Request] (StatsCollector-3:ctx-cc06edbb) Seq 3-7164945532169749796:
Received:  { Ans: , MgmtId: 227399391005010, via: 3, Ver: v1, Flags: 10, { GetStorageStatsAnswer
} }
> 2014-05-08 14:50:11,743 DEBUG [c.c.a.m.DirectAgentAttache] (DirectAgent-283:ctx-e100410a)
Seq 1-8742331301656267309: Executing request
> 2014-05-08 14:50:11,810 DEBUG [c.c.h.v.r.VmwareResource] (DirectAgent-283:ctx-e100410a
10.223.248.194) Datastore summary info, storageId: 70bb224b-0b11-3254-8ba1-339f0cf1d6ba, localPath:
/export/home/parth/49.210/primary, poolType: NetworkFilesystem, capacity: 11810778316800,
free: 2685316997120, used: 9125461319680
> 2014-05-08 14:50:11,810 DEBUG [c.c.a.m.DirectAgentAttache] (DirectAgent-283:ctx-e100410a)
Seq 1-8742331301656267309: Response Received:
> 2014-05-08 14:50:11,810 DEBUG [c.c.a.t.Request] (StatsCollector-3:ctx-cc06edbb) Seq 1-8742331301656267309:
Received:  { Ans: , MgmtId: 227399391005010, via: 1, Ver: v1, Flags: 10, { GetStorageStatsAnswer
} }
> 2014-05-08 14:50:12,003 DEBUG [o.a.c.s.SecondaryStorageManagerImpl] (secstorage-1:ctx-266b02ca)
Zone 1 is ready to launch secondary storage VM
> 2014-05-08 14:50:12,398 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-4:null)
SeqA 2-12952: Processing Seq 2-12952:  { Cmd , MgmtId: -1, via: 2, Ver: v1, Flags: 11, [{"com.cloud.agent.api.ConsoleProxyLoadReportCommand":{"_proxyVmId":2,"_loadInfo":"{\n
 \"connections\": []\n}","wait":0}}] }
> 2014-05-08 14:50:12,405 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-4:null)
SeqA 2-12952: Sending Seq 2-12952:  { Ans: , MgmtId: 227399391005010, via: 2, Ver: v1, Flags:
100010, [{"com.cloud.agent.api.AgentControlAnswer":{"result":true,"wait":0}}] }
> 2014-05-08 14:50:12,926 DEBUG [c.c.c.ConsoleProxyManagerImpl] (consoleproxy-1:ctx-42df7e16)
Zone 1 is ready to launch console proxy
>  
>  
>  



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message