[ui] Data fields on settings page are not validated.

Bug #1251232 reported by Anastasiia Naboikina on 2013-11-14
32
This bug affects 6 people
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Medium
Kate Pimenova

Bug Description

Steps to reproduce:
1. Create new cluster with any configuration.
2. Enter settings tab.
3. Enter 4 space symbols as admin name, erase values for admin password and tenant tenant, enter any symbols without "@" to e-mail.
4. Press "Save settings".
5. Add nodes, deploy cluster.

Expected result:
There is an error message on settings page, or at least at deployment start.

Actual result:
No error messages, cluster deployment starts successfully.

Changed in fuel:
importance: Undecided → High
importance: High → Medium
Dmitry Pyzhov (dpyzhov) on 2013-11-19
Changed in fuel:
assignee: Dmitry Pyzhov (lux-place) → Vitaly Kramskikh (vkramskikh)
Mike Scherbakov (mihgen) on 2013-12-02
Changed in fuel:
milestone: none → 4.1
Dmitry Pyzhov (dpyzhov) on 2013-12-10
tags: removed: fuelmenu library
Changed in fuel:
assignee: Vitaly Kramskikh (vkramskikh) → Fuel Python Team (fuel-python)
Nikolay Markov (nmarkov) on 2013-12-16
Changed in fuel:
status: New → Confirmed
Ivan Kolodyazhny (e0ne) on 2014-01-08
Changed in fuel:
assignee: Fuel Python Team (fuel-python) → Fuel UI Team (fuel-ui)
Changed in fuel:
assignee: Fuel UI Team (fuel-ui) → Julia Aranovich (jkirnosova)

Fix proposed to branch: master
Review: https://review.openstack.org/70334

Changed in fuel:
status: Confirmed → In Progress
Dmitry Pyzhov (dpyzhov) on 2014-02-14
Changed in fuel:
milestone: 4.1 → 5.0
Changed in fuel:
assignee: Julia Aranovich (jkirnosova) → Vitaly Kramskikh (vkramskikh)

Reviewed: https://review.openstack.org/70334
Committed: https://git.openstack.org/cgit/stackforge/fuel-web/commit/?id=3e499b1d1f64d0a7de4af5cf555f7621a06f8608
Submitter: Jenkins
Branch: master

commit 3e499b1d1f64d0a7de4af5cf555f7621a06f8608
Author: Julia Aranovich <email address hidden>
Date: Tue Mar 11 13:22:17 2014 +0400

    OpenStack Settings tab UI validation

    Closes-Bug: #1251232

    Change-Id: I047f431e034a4f16884e595e094eb0761fb6d3f3

Changed in fuel:
status: In Progress → Fix Committed

Bug is still reproducable on {"build_id": "2014-04-04_14-28-22", "mirantis": "yes", "build_number": "84", "nailgun_sha": "212ab310db2b91ad06b3f81eac435a252c2cb1c2", "ostf_sha": "17f2fe6e56452f8e2f01a385be4c4b87bf3698a8", "fuelmain_sha": "429fe222aadf12a4a2aadb092ad782eca5bf16e3", "astute_sha": "183fe05cd59a5ce6d154fa263a5a8bf5f27db0ec", "release": "5.0", "fuellib_sha": "57e64917a37bf22b10518a05a70b6bf435d7426a"}

Cluster deployment starts and ends up with errors on controller and compute nodes (see diagnostic snapshot)

Changed in fuel:
status: Fix Committed → New
Changed in fuel:
assignee: Vitaly Kramskikh (vkramskikh) → Julia Aranovich (jkirnosova)
Julia Aranovich (jkirnosova) wrote :

This issue refers to https://blueprints.launchpad.net/fuel/+spec/ui-openstack-settings-regexes
Regexps should be added in openstack.yaml configuration file.

Changed in fuel:
assignee: Julia Aranovich (jkirnosova) → nobody
Dima Shulyak (dshulyak) on 2014-04-08
Changed in fuel:
assignee: nobody → Fuel Python Team (fuel-python)
Dmitry Pyzhov (dpyzhov) on 2014-04-11
Changed in fuel:
milestone: 5.0 → 5.1
Dmitry Pyzhov (dpyzhov) on 2014-04-14
Changed in fuel:
status: New → Confirmed
Dima Shulyak (dshulyak) on 2014-06-20
tags: added: low-hanging-fruit
Dmitry Ilyin (idv1985) on 2014-07-15
summary: - Data fields on settings page are not validated.
+ [ui] Data fields on settings page are not validated.
Dmitry Pyzhov (dpyzhov) on 2014-07-28
Changed in fuel:
milestone: 5.1 → 6.0
Changed in fuel:
assignee: Fuel Python Team (fuel-python) → Przemyslaw Kaminski (pkaminski)
Przemyslaw Kaminski (pkaminski) wrote :

Here are the relevant regexpes in openstack.yaml:

    attributes_metadata:
      editable:
        access:
          metadata:
            label: "Access"
            weight: 10
          user:
            value: "admin"
            label: "username"
            description: "Username for Administrator"
            weight: 10
            type: "text"
            regex:
              source: &user_tenant_blacklist '^(?!services$)(?!nova$)(?!glance$)(?!keystone$)(?!neutron$)(?!cinder$)(?!swift$)(?!ceph$)(?![Gg]uest$)(?!.* +.*$).+'
              error: "Invalid username"
          email:
            value: "admin@localhost"
            label: "email"
            description: "Email address for Administrator"
            weight: 40
            type: "text"
            regex:
              source: ^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.?)+[a-z0-9]?(?:[a-z0-9-]*[a-z0-9])?
              error: "Invalid email"
          tenant:
            value: "admin"
            label: "tenant"
            description: "Tenant (project) name for Administrator"
            weight: 30
            type: "text"
            regex:
              source: *user_tenant_blacklist
              error: "Invalid tenant name"
          password:
            value: "admin"
            label: "password"
            description: "Password for Administrator"
            weight: 20
            type: "password"
            regex:
              source: .+
              error: "Invalid password"

I'd add a 'required' option so that we can replace those '.*'. This was tested as working against current master (35946b1f225c984f11915ba8e985584160f0b129) but since settings are being rewritten this bug is being postponed until https://blueprints.launchpad.net/openstack/?searchtext=backbone-to-react is finished.

Changed in fuel:
assignee: Przemyslaw Kaminski (pkaminski) → Fuel Python Team (fuel-python)
Dmitry Pyzhov (dpyzhov) on 2014-11-18
Changed in fuel:
milestone: 6.0 → 6.1
Dmitry Pyzhov (dpyzhov) on 2014-11-18
tags: removed: low-hanging-fruit
Changed in fuel:
assignee: Fuel Python Team (fuel-python) → Kate Pimenova (kpimenova)

Fix proposed to branch: master
Review: https://review.openstack.org/156966

Changed in fuel:
status: Confirmed → In Progress

Reviewed: https://review.openstack.org/156966
Committed: https://git.openstack.org/cgit/stackforge/fuel-web/commit/?id=83d649fcb8e8f5d08556c4a963693143db074e4b
Submitter: Jenkins
Branch: master

commit 83d649fcb8e8f5d08556c4a963693143db074e4b
Author: Kate Pimenova <email address hidden>
Date: Wed Feb 18 15:12:50 2015 +0300

    Validation data fields on settings page

    Closes-Bug:#1251232

    Change-Id: I1d9a0c8e0123dc4e082cb13095f0e41552d3a0aa

Changed in fuel:
status: In Progress → Fix Committed
Anastasia Palkina (apalkina) wrote :

Verified on ISO #135

"build_id": "2015-02-19_22-54-44", "ostf_sha": "a4cd80d28b3f173b6e1e32fa3485fe7c893f4db3", "build_number": "135", "release_versions": {"2014.2-6.1": {"VERSION": {"build_id": "2015-02-19_22-54-44", "ostf_sha": "a4cd80d28b3f173b6e1e32fa3485fe7c893f4db3", "build_number": "135", "api": "1.0", "nailgun_sha": "8a1e03b5863f4e91981278f154b088069415efae", "production": "docker", "python-fuelclient_sha": "5657dbf06fddb74adb61e9668eb579a1c57d8af8", "astute_sha": "e5666ad8b556727f7cf73b17831f7863de325a5b", "feature_groups": ["mirantis"], "release": "6.1", "fuelmain_sha": "b975019fabdb429c1869047df18dd792d2163ecc", "fuellib_sha": "ae1d6fb47203a30a90dd1c845d8291320bf5b5d6"}}}, "auth_required": true, "api": "1.0", "nailgun_sha": "8a1e03b5863f4e91981278f154b088069415efae", "production": "docker", "python-fuelclient_sha": "5657dbf06fddb74adb61e9668eb579a1c57d8af8", "astute_sha": "e5666ad8b556727f7cf73b17831f7863de325a5b", "feature_groups": ["mirantis"], "release": "6.1", "fuelmain_sha": "b975019fabdb429c1869047df18dd792d2163ecc", "fuellib_sha": "ae1d6fb47203a30a90dd1c845d8291320bf5b5d6"

Changed in fuel:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers