Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gelencsér Szabolcs
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
e029a56b
authored
Jan 09, 2014
by
Bach Dániel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
firewall: add vlan acl levels
parent
2c0ff8d8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletions
+6
-1
circle/firewall/models.py
+6
-1
No files found.
circle/firewall/models.py
View file @
e029a56b
...
@@ -17,6 +17,7 @@ from django.db.models.signals import post_save, post_delete
...
@@ -17,6 +17,7 @@ from django.db.models.signals import post_save, post_delete
import
random
import
random
from
firewall.tasks.local_tasks
import
reloadtask
from
firewall.tasks.local_tasks
import
reloadtask
from
acl.models
import
AclBase
logger
=
logging
.
getLogger
(
__name__
)
logger
=
logging
.
getLogger
(
__name__
)
settings
=
django
.
conf
.
settings
.
FIREWALL_SETTINGS
settings
=
django
.
conf
.
settings
.
FIREWALL_SETTINGS
...
@@ -157,7 +158,7 @@ class Rule(models.Model):
...
@@ -157,7 +158,7 @@ class Rule(models.Model):
)
)
class
Vlan
(
models
.
Model
):
class
Vlan
(
AclBase
,
models
.
Model
):
"""
"""
A vlan of the network,
A vlan of the network,
...
@@ -170,6 +171,10 @@ class Vlan(models.Model):
...
@@ -170,6 +171,10 @@ class Vlan(models.Model):
range. The gateway also has an IP address in each range.
range. The gateway also has an IP address in each range.
"""
"""
ACL_LEVELS
=
(
(
'user'
,
_
(
'user'
)),
(
'operator'
,
_
(
'operator'
)),
)
CHOICES_NETWORK_TYPE
=
((
'public'
,
_
(
'public'
)),
(
'dmz'
,
_
(
'dmz'
)),
CHOICES_NETWORK_TYPE
=
((
'public'
,
_
(
'public'
)),
(
'dmz'
,
_
(
'dmz'
)),
(
'portforward'
,
_
(
'portforward'
)))
(
'portforward'
,
_
(
'portforward'
)))
vid
=
models
.
IntegerField
(
unique
=
True
,
vid
=
models
.
IntegerField
(
unique
=
True
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment