You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
47 lines
1.9 KiB
Python
47 lines
1.9 KiB
Python
# abac/urls.py
|
|
|
|
from django.contrib.auth import views as auth_views
|
|
from django.urls import path
|
|
|
|
from .views import (
|
|
landing_page,
|
|
logout_view,
|
|
upload_file_view,
|
|
create_user_view,
|
|
upload_certificate_view,
|
|
file_detail,
|
|
create_rule,
|
|
rule_detail,
|
|
user_detail_view,
|
|
delete_rule_attribute,
|
|
download_file,
|
|
user_management,
|
|
upload_public_key,
|
|
hierarchy_view,
|
|
trusted_authorities,
|
|
delete_authority,
|
|
verify_decryption
|
|
)
|
|
|
|
app_name = 'abac'
|
|
|
|
urlpatterns = [
|
|
path('', landing_page, name='home'),
|
|
path('login/', auth_views.LoginView.as_view(template_name='login.html', success_url='/'), name='login'),
|
|
path('logout/', logout_view, name='logout'),
|
|
path('upload-file/', upload_file_view, name='upload_file'),
|
|
path('create-user/', create_user_view, name='create_user'),
|
|
path('upload-certificate/', upload_certificate_view, name='upload_certificate'),
|
|
path('files/<int:file_id>/', file_detail, name='file_detail'),
|
|
path('files/<int:file_id>/create_rule/', create_rule, name='create_rule'),
|
|
path('rules/<int:file_id>/<int:rule_id>/',rule_detail, name='rule_detail'),
|
|
path('user/<str:username>/', user_detail_view, name='user_details'),
|
|
path('rules/<int:file_id>/<int:rule_id>/delete/<int:rule_attribute_id>/', delete_rule_attribute, name='delete_rule_attribute'),
|
|
path('downloader/<int:file_id>/', download_file, name='download_file'),
|
|
path('user_management/', user_management, name='user_management'),
|
|
path('user/<str:username>/upload-public-key', upload_public_key, name='upload_public_key'),
|
|
path('visualization/hierarchical', hierarchy_view, name='hierarchy_vis'),
|
|
path('trusted-authorities', trusted_authorities, name="trusted_authorities"),
|
|
path('trusted-authorities/delete/<int:authority_id>/', delete_authority, name='delete_authority'),
|
|
path('verify_decryption', verify_decryption, name='verify_decryption')
|
|
] |