Skip to content

Commit

Permalink
Remove minio root credentials from CreateTenant response (#402)
Browse files Browse the repository at this point in the history
Co-authored-by: Daniel Valdivia <hola@danielvaldivia.com>
  • Loading branch information
cesnietor and dvaldivia committed Nov 19, 2020
1 parent b21123e commit 12e53a1
Show file tree
Hide file tree
Showing 7 changed files with 1 addition and 40 deletions.
6 changes: 0 additions & 6 deletions models/create_tenant_response.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -82,14 +82,6 @@ const CredentialsPrompt = ({
<Grid container>
<Grid item xs={12} className={classes.formScrollable}>
A new {entity} has been created with the following details:
<ul>
<li>
<b>Access Key:</b> {newServiceAccount.accessKey}
</li>
<li>
<b>Secret Key:</b> {newServiceAccount.secretKey}
</li>
</ul>
{consoleCreds && (
<React.Fragment>
<Grid item xs={12}>
Expand Down Expand Up @@ -131,8 +123,6 @@ const CredentialsPrompt = ({
download(
"credentials.json",
JSON.stringify({
access_key: newServiceAccount.accessKey,
secret_key: newServiceAccount.secretKey,
...consoleExtras,
})
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@
// along with this program. If not, see <http://www.gnu.org/licenses/>.

export interface NewServiceAccount {
accessKey: string;
secretKey: string;
console?: ConsoleSA;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -913,8 +913,6 @@ const AddTenant = ({
.invoke("POST", `/api/v1/tenants`, dataSend)
.then((res) => {
const newSrvAcc: NewServiceAccount = {
accessKey: res.access_key,
secretKey: res.secret_key,
console: {
accessKey: res.console.access_key,
secretKey: res.console.secret_key,
Expand Down
5 changes: 1 addition & 4 deletions restapi/admin_tenants.go
Original file line number Diff line number Diff line change
Expand Up @@ -778,10 +778,7 @@ func getTenantCreatedResponse(session *models.Principal, params admin_api.Create
return nil, prepareError(err)
}
}
response = &models.CreateTenantResponse{
AccessKey: accessKey,
SecretKey: secretKey,
}
response = &models.CreateTenantResponse{}
// Attach Console Credentials
if enableConsole {
response.Console = &models.CreateTenantResponseConsole{
Expand Down
12 changes: 0 additions & 12 deletions restapi/embedded_spec.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 0 additions & 4 deletions swagger.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2967,10 +2967,6 @@ definitions:
createTenantResponse:
type: object
properties:
access_key:
type: string
secret_key:
type: string
console:
type: object
properties:
Expand Down

0 comments on commit 12e53a1

Please sign in to comment.