User management system (UMS), has the primary purpose of connecting to an Active Directory (AD)

Related tags

MiscellaneousSGU
Overview

💿 Sistema de Gerenciamento de Usuário (SGU)

📚 Sobre o projeto

Sistema de gerenciamento de usuários (SGU), tem o objetivo primário de se conectar a um Active Directory (AD). A motivação do projeto é justamente para ambientes que possuem algum tipo de AD e possuem outros sistemas web's internos. Afim de evitar um número alto de diferentes login's e senhas, nessa ocasião, é interessante utilizar as mesmas informações do AD para a autenticação. O projeto está em formato de API básica, sem as métricas avançadas de segurança, pois o foco desse projeto é apenas demonstrar uma conexão básica entre um sistema em Django e o AD.


💻 Tecnologias

O sistema foi desenvolvido em python com a framework Django. Além disso, utilizei a biblioteca "Django Auth Ldap", onde a mesma faz uso da biblioteca "ldap3", porém, ja modificada especificamente para fazer as métricas de autenticação com o AD. Por fim, utilizei a framework "Django rest framework", para configurar com facilidade uma API.


Funcionamento

Através de uma requisição tipo POST, é passado no corpo da requisição o usuário e senha.

Após o sistema receber essa requisição, ele consultará o AD para verificar se esse usuário existe. Caso o usuário exista e a senha esteja correta , ele cadastra no próprio banco de dados do Django, ele retorna os dados em formato JSON. Caso o usuário ja exista, ele não cadastra no banco de dados e retorna os dados em JSON. Mas caso não exista ou a senha esteja incorreta, ele apenas retorna um Not Found 404.

A cada requisição de autenticação, o sistema verifica se houve alguma modificação do setor do usuário. Caso o setor tenha sido mudado no AD, o sistema alterará no banco de dados do Django. Para a alteração de setor automática funcionar, é necessário que o nome do setor no banco de dados do Django seja exatamente igual ao grupo no AD


🎨 Algumas imagens


⚠️ Atenção

Provavelmente você irá utilizar o arquivo "requeriments.txt" para fazer a instalação dos pacotes. Porém, caso esteja utilizando o Windows, provavelmente irá ocorrer um erro com a biblioteca "ldap3". Caso ocorra esse erro, no repositório tem um arquivo chamado "python_ldap-3.2.0-cp36-cp36m-win_amd64.whl", onde é o instalador manual para windows 64 bits. Poderá ser instalado através do comando "pip install python_ldap-3.2.0-cp36-cp36m-win_amd64".

🔗 Links úteis

https://techexpert.tips/pt-br/django-pt-br-2/django-autenticacao-ldap-no-diretorio-ativo/

https://ldap3.readthedocs.io/en/latest/

https://django-auth-ldap.readthedocs.io/en/latest/

https://www.django-rest-framework.org/

Owner
Patrick Viegas
Patrick Viegas
Kubernetes-native workflow automation platform for complex, mission-critical data and ML processes at scale. It has been battle-tested at Lyft, Spotify, Freenome, and others and is truly open-source.

Flyte Flyte is a workflow automation platform for complex, mission-critical data, and ML processes at scale Home Page · Quick Start · Documentation ·

Flyte 3k Jan 01, 2023
TimeWizard - A script that generates every single Time Wizard EDOPRO lflist possible

EDOPRO F&L list generator This project is just a script that generates every sin

Diamond Dude 2 Sep 28, 2022
scap is a tool for putting code in places and for other purposes

Scap is the deployment script used by Wikimedia Foundation to publish code and configuration on production web servers.

Wikimedia 7 Nov 02, 2022
Beacon Object File (BOF) to obtain a usable TGT for the current user.

Beacon Object File (BOF) to obtain a usable TGT for the current user.

Connor McGarr 109 Dec 25, 2022
Write-ups for CTF Internacional MetaRed 2021 5th stage

MetaRed2021-5th-Writeups Write-ups for CTF Internacional MetaRed 2021 5th stage Easy (15) No Status Category Name Creator(s) 01 Done osint Cybersecuri

UA Cybersecurity 2 Dec 22, 2021
3x+1 recreated in Python

3x-1 3x+1 recreated in Python If a number is odd it is multiplied by 3 and 1 is added to the product. If a number is even it is divided by 2. These ru

4 Aug 19, 2022
The worst and slowest programming language you have ever seen

VenumLang this is a complete joke EXAMPLE: fizzbuzz in venumlang x = 0

Venum 7 Mar 12, 2022
A Snakemake workflow for standardised sc/snRNAseq analysis

single_snake_sequencing - sc/snRNAseq Snakemake Workflow A Snakemake workflow for standardised sc/snRNAseq analysis. Every single cell analysis is sli

IMS Bio2Core Facility 1 Nov 02, 2021
Framework To Ease Operating with Quantum Computers

QType Framework To Ease Operating with Quantum Computers Concept # define an array of 15 cubits:

Antonio Párraga Navarro 2 Jun 06, 2022
Random Programming Language Project

Crastle Random Programming Language Project Freedom of expression Are you a fan of curly brace languages? Then use curly braces! Not a fan of curly br

DevNugget 2 Dec 23, 2021
Repository for my Monika Assistant project

Monika_Assistant Repository for my Monika Assistant project Major changes: Added face tracker Added manual daily log to see how long it takes me to fi

3 Jan 10, 2022
A joke conlang with minimal semantics

SyntaxLang Reserved Defined Words Word Function fo Terminates a noun phrase or verb phrase tu Converts an adjective block or sentence to a noun to Ter

Leo Treloar 1 Dec 07, 2021
ioztat is a storage load analysis tool for OpenZFS

ioztat is a storage load analysis tool for OpenZFS. It provides iostat-like statistics at an individual dataset/zvol level.

Jim Salter 116 Nov 25, 2022
This is a calculator of strike price distance for options.

Calculator-of-strike-price-distance-for-options This is a calculator of strike price distance for options. Options are a type of derivative. One strat

André Luís Lopes da Silva 4 Dec 30, 2022
OLDBot (Online Lessons Discord Bot)

This program is designed to facilitate online lessons. With this you don't need to get up early. Just config and watch the program resolve itself. It automatically enters to the lesson at the specifi

Da4ndo 1 Nov 21, 2021
El_Binario - A converter for Binary, Decimal, Hexadecimal and Octal numbers

El_Binario El_Binario es un conversor de números Binarios, Decimales, Hexadecima

2 Jan 28, 2022
NeurIPS'19: Meta-Weight-Net: Learning an Explicit Mapping For Sample Weighting (Pytorch implementation for noisy labels).

Meta-Weight-Net NeurIPS'19: Meta-Weight-Net: Learning an Explicit Mapping For Sample Weighting (Official Pytorch implementation for noisy labels). The

243 Jan 03, 2023
Interfaces between napari and pymeshlab library to allow import, export and construction of surfaces.

napari-pymeshlab Interfaces between napari and the pymeshlab library to allow import, export and construction of surfaces. This is a WIP and feature r

Zach Marin 4 Oct 12, 2022
*考研学习利器,玩电脑控制不住自己时,可以使用该程序定日期锁屏,同时有精美壁纸锁屏显示,也不会枯燥。

LockscreenbyTime_win10 A python program in win10. You can set the time to lock the computer(by setting year, month, day), Fullscreen pictures will sho

PixianDouban 4 Jul 10, 2022
A collection of simple tools that proved to be needed for hadling large periodic calculations with the VASP software package.

VESTA-tools A collection of simple tools that proved to be needed for handling large periodic calculations with the VASP software package. distTotCalc

Ilia Kichev 2 Dec 14, 2021