[qos] No error handling while configuring Forwarding Class

Bug #1605195 reported by Pulkit Tandon
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
R3.1
Won't Fix
High
Naveen N
Trunk
Fix Released
High
Naveen N

Bug Description

While creating a FC, any integer value of dscp,exp or dot1p acceptable.
Need to have a check on that.

Even FC ID can be restricted to a value from 0 to 255

{
    "forwarding-class": {
        "display_name": "700",
        "forwarding_class_dscp": 92,
        "forwarding_class_id": 700,
        "forwarding_class_mpls_exp": 76,
        "forwarding_class_vlan_priority": 24,
        "fq_name": [
            "default-global-system-config",
            "default-global-qos-config",
            "700"
        ],

Apart from this, there is no check ofr FC ID being an integer or a string.
FC ID should be an integer.
We have a different field "name" for name of FC_ID

root@nodeh4:~/fabric-utils# curl -u admin:contrail123 http://127.0.0.1:8095/forwarding-class/9f10d7ff-8478-48e7-a81e-310b053c2111 | python -mjson.tool
  % Total % Received % Xferd Average Speed Time Time Time Current
                                 Dload Upload Total Spent Left Speed
100 957 100 957 0 0 173k 0 --:--:-- --:--:-- --:--:-- 186k
{
    "forwarding-class": {
        "display_name": "Yipee",
        "fq_name": [
            "default-global-system-config",
            "default-global-qos-config",
            "Yipee"
        ],

Because of no check in config, UI also accepts all inputs.
Proper error should be thrown.
After fix, UI also need to be tested for FC provisioning.

Tags: qos
Pulkit Tandon (pulkitt)
description: updated
summary: - [qos] No check on values of dscp/vlan/exp mentioned in FC
+ [qos] No error handling while configuring Forwarding Class
description: updated
Changed in juniperopenstack:
importance: Medium → High
information type: Proprietary → Public
Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/22462
Submitter: Naveen N (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] R3.1

Review in progress for https://review.opencontrail.org/22526
Submitter: Naveen N (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/22526
Committed: http://github.org/Juniper/contrail-controller/commit/d69e47f551072ec61727cac4f276a824d06ddcf6
Submitter: Zuul
Branch: R3.1

commit d69e47f551072ec61727cac4f276a824d06ddcf6
Author: Naveen N <email address hidden>
Date: Wed Jul 27 10:21:57 2016 +0530

* Add checks for DSCP, MPLS exp and 802.1p values

Change-Id: I70a944978e1c12f0e25d6adf1e7427954ee16f63
Closes-bug:#1605195

Revision history for this message
Vedamurthy Joshi (vedujoshi) wrote :

Naveen, this fix does not seem to be working... On build 11 where i can see this commit, i can configure an fc with dscp/mpls/dot1p with value 100 from UI...

In vrouter, i see this..

root@nodek2:~# qosmap --get-fc 10
Forwarding Class Map 0
 FC DSCP EXP .1p Queue
 10 100 4 4 0
root@nodek2:~#

Revision history for this message
Pulkit Tandon (pulkitt) wrote :

As Vedu mentioned, fix not working properly.
Hence changed the status of bug to "New"

Revision history for this message
Hari Prasad Killi (haripk) wrote :

The fix for this is dependent on <https://bugs.launchpad.net/juniperopenstack/+bug/1599733>. The latter is not being fixed for R3.1. Hence marking the same here as well.

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/22462
Submitter: Sachin Bansal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/22462
Committed: http://github.org/Juniper/contrail-controller/commit/114c5eaba4f15ca560835a8eb35c50226709ff2b
Submitter: Zuul
Branch: master

commit 114c5eaba4f15ca560835a8eb35c50226709ff2b
Author: Naveen N <email address hidden>
Date: Wed Jul 27 10:21:57 2016 +0530

* Add checks for DSCP, MPLS exp and 802.1p values

Change-Id: I70a944978e1c12f0e25d6adf1e7427954ee16f63
Closes-bug:#1605195

Revision history for this message
Pulkit Tandon (pulkitt) wrote :

Tested on R3.2 - build 2.
It's working as expected.
Any invalid values are not acceptable

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.