Skip to content

Conversation

@jhadvig
Copy link
Member

@jhadvig jhadvig commented Jan 18, 2018

Fixed wrong input names in the create-secret.html
@jwforres PTAL

@openshift-ci-robot openshift-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Jan 18, 2018
@jwforres
Copy link
Member

the bug says webhook secret key is not being validated, I dont see how this fixes that issue?

@jhadvig
Copy link
Member Author

jhadvig commented Jan 18, 2018

@jwforres so since we are not doing any kind of validation of the secret key, but I've noticed that the secret name was not validated properly, since the input name was different from the name that that was checked on the form (and for some other input fields as well).
Sorry I've forgot to clarify it in the first comment.

@jwforres
Copy link
Member

ok i know on the original set of changes i said not to worry about the validation, but now we can probably look into it as a follow-on here. webhook secret key needs to be a valid URL path segment. Thats probably the only validation we should try to do.

@openshift-ci-robot openshift-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Jan 24, 2018
@jhadvig
Copy link
Member Author

jhadvig commented Jan 24, 2018

@jwforres PTAL

$scope.secretReferenceValidation = {
pattern: /^[a-zA-Z0-9\-_]+$/,
minLength: 8,
description: 'Secret reference key must consist of lower-case, upper-case letters, numbers, bash and underscore.'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dash not bash, also we use oxford commas here

"dash, and underscore"

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

always forgetting about the commas. We dont use int with 'and' ... sorry

</div>
<div class="has-error" ng-show="secretForm.webhookSecretKey.$error.minlength && secretForm.webhookSecretKey.$touched">
<span class="help-block">
Minimum character count is {{secretReferenceValidation.minLength}}.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like you got this message from the env editor, but I prefer what we say in other places which is something like:

The key must have at least 8 characters.

@jhadvig
Copy link
Member Author

jhadvig commented Jan 24, 2018

@jwforres comments addressed. added dist as well.

@jwforres
Copy link
Member

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Jan 24, 2018
@openshift-merge-robot
Copy link
Contributor

Automatic merge from submit-queue.

@openshift-merge-robot openshift-merge-robot merged commit e92e0cf into openshift:master Jan 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants