In openconfig-ospfv2-area-interface shouldn't we define Authentication type some generic type
Closed this issue · 3 comments
Here in the openconfig-ospfv2-area-interface.yang , the authentication-type is defined as a string . The authentication-type needs to defined as a generic type something like oc-auth-types:auth-type. And then such type can be inherited in other models also . It will be easier to extend and make it more generic .
Purposed changes
diff --git a/release/models/ospf/openconfig-ospfv2-area-interface.yang b/release/models/ospf/openconfig-ospfv2-area-interface.yang
index cd8836c..caa4acc 100644
--- a/release/models/ospf/openconfig-ospfv2-area-interface.yang
+++ b/release/models/ospf/openconfig-ospfv2-area-interface.yang
@@ -9,6 +9,7 @@ submodule openconfig-ospfv2-area-interface {
import openconfig-types { prefix "oc-types"; }
import openconfig-interfaces { prefix "oc-if"; }
import openconfig-ospf-types { prefix "oc-ospf-types"; }
-
import openconfig-aaa-types { prefix oc-aaa-types; }
// include common submodule
include openconfig-ospfv2-common;
@@ -83,12 +84,9 @@ submodule openconfig-ospfv2-area-interface {
}leaf authentication-type {
-
type string;
-
// rjs TODO: discuss with bogdanov@ what the approach for auth
-
// links should be.
-
type oc-aaa-types:auth-type; description "The type of authentication that should be used on this interface";
}
leaf metric {
@@ -463,4 +461,4 @@ submodule openconfig-ospfv2-area-interface {
}
}
-}
\ No newline at end of file
+}
diff --git a/release/models/system/openconfig-aaa-types.yang b/release/models/system/openconfig-aaa-types.yang
index 57ca20d..deaa142 100644
--- a/release/models/system/openconfig-aaa-types.yang
+++ b/release/models/system/openconfig-aaa-types.yang
@@ -151,6 +151,28 @@ module openconfig-aaa-types {
These may not all be supported by a target device.";
}
- typedef auth-type {
- type enumeration {
-
enum NONE {
-
description
-
"This means No authentication that should be used on this
-
interface";
-
}
-
enum SIMPLE {
-
description
-
"This means simple/plain-text authentication that should be
-
used on this interface";
-
}
-
enum MD5 {
-
description
-
"This means MD5 authentication that should be used on this
-
interface";
-
}
- }
- description
-
"A common type used to express the type of Authentication that is
-
used on an interface";
- }
}
Hi! @addogra, How are you doing?
Do you have any update about this issue, and this update has the key field to authentication type?
Thanks!!
This issue is stale because it has been open 180 days with no activity. If you wish to keep this issue active, please remove the stale label or add a comment, otherwise will be closed in 14 days.