925 Commits

Author SHA1 Message Date
Wilder Rodrigues
869f0ad375 replacing my IP by localhost to avoid problems with my environment 2014-10-14 15:01:12 +02:00
Wilder Rodrigues
65d7e0756d Adding Firewall Rules to comply with the Visitor pattern implementation; refactoring the applyRules so we can reuse it.
Conflicts:
	server/src/com/cloud/network/rules/LoadBalancingRules.java
	server/src/com/cloud/network/topology/AdvancedNetworkVisitor.java
	server/src/com/cloud/network/topology/BasicNetworkTopology.java
	server/src/com/cloud/network/topology/NetworkTopology.java
2014-10-14 14:55:22 +02:00
Damodar
50185b7c3a CLOUDSTACK-7648: There are new VM State Machine changes introduced which were missed to capture the usage events 2014-10-13 14:42:00 +05:30
Santhosh Edukulla
31a42d2b7a Fixed few coverity patches
Signed-off-by: Santhosh Edukulla <santhosh.edukulla@gmail.com>
2014-10-09 11:45:26 +05:30
Anshul Gangwar
7972f53c8d CLOUDSTACK-7575: improved performance of cleanString method in StringUtils 2014-09-26 14:02:41 +05:30
Hugo Trippaers
6f54d48772 CID-1116298 path can be null, make sure that is properly handled 2014-09-19 11:54:21 +02:00
Frank Zhang
8b89494a35 CLOUDSTACK-6278
Baremetal Advanced Networking support
2014-09-18 16:54:37 -07:00
Hugo Trippaers
d1d8009c68 Fix a stupid bug i introduced 2014-09-18 16:02:26 +02:00
Rohit Yadav
bd1752811c CID-1116250: Lock on s_appContextDelegates before calling get in ComponentContext
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-09-18 11:52:18 +02:00
Rohit Yadav
ec134cf010 CID-1116231: Use implicit lock, synchronize _key in Link
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-09-18 11:21:57 +02:00
Hugo Trippaers
577a2f40b3 Merge branch 'bugfix/CID-116538' 2014-09-17 11:40:55 +02:00
Rohit Yadav
88c6072b4d CID-1237196: Fix potential NPE in SAMLUtils
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-09-16 17:10:11 +02:00
Hugo Trippaers
de26a7228e Fix resource leaks on exception paths
Make it clear that the server socket isn't a leaked resource
2014-09-16 16:43:32 +02:00
Rohit Yadav
d46e45991d SAMLUtils: put name id policy on authnrequest
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-09-12 17:11:06 +02:00
Rohit Yadav
84b0e9e96f utils: add missing string to the url in generate saml signature method
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-09-12 16:26:13 +02:00
Rohit Yadav
5a0ed8764b SAMLUtils: Fix NPE incase signature is generated with a null privateKey
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-09-12 15:46:44 +02:00
Rohit Yadav
a66127dfb1 utils: add methods to save and load public and private keys
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-09-12 15:40:49 +02:00
Anshul Gangwar
d90a2d3962 CLOUDSTACK-7370: Fixed password visible in plain text if password passed is in the end in url 2014-09-12 15:33:24 +05:30
Frank.Zhang
10544e287b CLOUDSTACK-6278
Baremetal Advanced Networking support
2014-09-05 16:28:34 -07:00
Hugo Trippaers
dc3f0cbc63 Improve the handling of the findbug exclude files 2014-09-03 10:41:22 +02:00
Rohit Yadav
550762a0dc SAMLUtils: fix signature, refactor generateRandomX509Certificate
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-30 21:37:55 +02:00
Rohit Yadav
12ad5ba197 SAMLUtilsTest: just test that random secure string has some length
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-30 15:37:52 +02:00
Rohit Yadav
2bff5956a9 cisco-vnmc: Don't create Protocol using deprecated SecureProtocolSocketFactory
Latest httpclient library suggests when creating Protocol object for use
with the apache common httpclient class, they should avoid using the
deprecated Protocol signature which takes in SecureProtocolSocketFactory

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-29 14:39:29 +02:00
Rohit Yadav
5e7928bcb9 utils: fix static certificate value string in SAMLUtils
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-28 19:45:27 +02:00
Rohit Yadav
1ed532fb20 SAMLUtils: add unit test for SAMLUtils and method to randomly generate X509 certs
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-28 19:45:26 +02:00
Rohit Yadav
3bf387c882 SAMLUtils: Create new NameID using passed nameId taking just id and session idx
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-28 19:45:26 +02:00
Rohit Yadav
8dc50927f9 saml: use SAML_RESPONSE from SAMLUtils
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-28 19:45:26 +02:00
Rohit Yadav
230e970569 SAMLUtils: add logout request utility for saml slo
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-28 19:45:25 +02:00
Rohit Yadav
8fa9d2c276 utils: fix SAMLUtils's authnrequest maker
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-28 19:45:25 +02:00
Rohit Yadav
8e6cb04480 SAMLUtils: leave bootstrapping to upper layers
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-28 19:45:24 +02:00
Rohit Yadav
1b0f81ec6f utils: Remove hard coded strings from SAMLUtils
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-28 19:45:23 +02:00
Rohit Yadav
d6ea4ad7e0 utils: refactor and aggregate methods in SAMLUtils
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-28 19:45:22 +02:00
Rohit Yadav
7ada4ad50b NetUtils: Check for NPE in getDefaultHostIp method when processing nic/mac
On hosts or containers where they don't have valid mac address on nic resulting
in null, NetUtils.getNetworkParam can throw NPE.

This was a case found on TravisCI where OpenVZ containers are used. This method
(getDefaultHostIp) is used at several other places within the ACS codebase to
get the host IP and if null is caught we fallback to localhost or 127.0.0.1, so
we therefore set info to null before trying to process network param and if we
fail we return null and expect other layers to use localhost.

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-21 11:41:07 +02:00
Santhosh Edukulla
023811286e Fixed few coverity issues
Signed-off-by: Santhosh Edukulla <santhosh.edukulla@gmail.com>
2014-08-19 22:01:15 +05:30
Rohit Yadav
3b5aa42c6d CLOUDSTACK-4770: In MacAddress skip macAddress when parsed value is 0x00
In MacAddress class, we start by settig macAddress String as null and go through
the output of ifconfig -a and pick the one string that is a valid mac address
but is not 0x00 and 0xff. With each loop we set the macAddress to null so that
it does not pick the last one if everything fails.

Tested on Ubuntu where I had an interface called cloud0 whose mac id was 0x00
and it was skipped to get the next one:

$ java -classpath <path-to-cloud-utils.jar> com.cloud.utils.net.MacAddress
addr in integer is 5071953436
addr in bytes is  0 1 2e 4f de 1c
addr in char is 00:01:2e:4f:de:1c

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-13 15:04:04 +02:00
Min Chen
a22abeb0e7 CLOUDSTACK-7328:[Automation] Register ISO failing with invalid iso
format error.
2014-08-12 15:26:50 -07:00
Min Chen
e3564658be CLOUDSTACK-6940, CLOUDSTACK-7312, CLOUDSTACK-5512: Template/ISO/Volume
upload rejects some valid URL formats. Also consolidate URL format check
into one util routine.
2014-08-12 11:43:08 -07:00
Rohit Yadav
bae8f2a8cb utils: fix pom.xml to have references for javax.servlet api interfaces
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-12 12:01:32 +02:00
Rohit Yadav
315feb0683 utils: refactor HTTP transport stuff to HttpUtils
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-08-12 12:01:31 +02:00
Santhosh Edukulla
fd96ad02d7 Fixed few coverity reported issues around concurrency, null checks 2014-08-11 16:55:23 +05:30
Jayapal
d28da9d986 CLOUDSTACK-7212: Failed creating LB rule on public port 8081 for VR as LB provider 2014-08-01 15:54:17 +05:30
Alena Prokharchyk
89017a7d7b CS-19072: got rid of unneeded type casting when apply pagination to different resources 2014-07-30 10:33:45 -07:00
Alena Prokharchyk
ca8d3672e8 listNetworks: moved pagination post processing to StringUtils class 2014-07-28 14:43:55 -07:00
Hugo Trippaers
47bb175bd4 Partially reverting c61c636ce8a1d74fd22d89026d40ba904fff6cf8. Changing the name if cloud.keystore has bigger impact than just changing the name. 2014-07-28 14:52:41 +02:00
Kishan Kavala
c61c636ce8 CLOUDSTACK-5946: Commit 2774b62d64989bddc1e4664ef7a93dff11c77657 changed keystore file along with coverity fixes. Use varible name for keystore filename to keep it in sync 2014-07-25 14:07:46 +05:30
amoghvk
c804660c74 CLOUDSTACK-7168: Revert "Fixed Coverity Issues reported" that broke CI
This reverts commit 4523490d44160b054de9e943f72db1d0ce06054a.
2014-07-23 11:37:36 -07:00
Santhosh Edukulla
4523490d44 Fixed Coverity Issues reported
Signed-off-by: Santhosh Edukulla <santhosh.edukulla@gmail.com>
2014-07-22 18:03:36 +05:30
Rajani Karuturi
58bad41910 Fixed CLOUDSTACK-6983: unable to register lxc template
added a check for tar.gz format in checktemplate
2014-07-21 16:57:53 +05:30
Edison Su
51c14106d8 CLOUDSTACK-7123: set the timeout to 60s, when run the file command 2014-07-18 12:07:36 -07:00
Mike Tutkowski
b080eaf327 Updates to the way resizing a volume works 2014-07-17 21:09:19 -06:00