Skip to content

Commit 5ff83e9

Browse files
Amogh Vasekarfrank
authored andcommitted
Adding encryption flag
CLOUDSTACK-3308 UCS:DB: UCS Manager password should not get stored in plain text.
1 parent 04cdd90 commit 5ff83e9

1 file changed

Lines changed: 9 additions & 4 deletions

File tree

plugins/hypervisors/ucs/src/com/cloud/ucs/database/UcsManagerVO.java

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
// to you under the Apache License, Version 2.0 (the
66
// "License"); you may not use this file except in compliance
77
// with the License. You may obtain a copy of the License at
8-
//
8+
//
99
// http://www.apache.org/licenses/LICENSE-2.0
10-
//
10+
//
1111
// Unless required by applicable law or agreed to in writing,
1212
// software distributed under the License is distributed on an
1313
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -27,6 +27,8 @@
2727
import org.apache.cloudstack.api.Identity;
2828
import org.apache.cloudstack.api.InternalIdentity;
2929

30+
import com.cloud.utils.db.Encrypt;
31+
3032
@Entity
3133
@Table(name="ucs_manager")
3234
public class UcsManagerVO implements InternalIdentity, Identity {
@@ -50,16 +52,19 @@ public class UcsManagerVO implements InternalIdentity, Identity {
5052
@Column(name="username")
5153
private String username;
5254

55+
@Encrypt
5356
@Column(name="password")
5457
private String password;
5558

56-
public long getId() {
59+
@Override
60+
public long getId() {
5761
return id;
5862
}
5963
public void setId(long id) {
6064
this.id = id;
6165
}
62-
public String getUuid() {
66+
@Override
67+
public String getUuid() {
6368
return uuid;
6469
}
6570
public void setUuid(String uuid) {

0 commit comments

Comments
 (0)