{"id":20245813,"url":"https://github.com/pranosa/samba_project_backends","last_synced_at":"2026-05-23T16:34:05.585Z","repository":{"id":192764603,"uuid":"686126504","full_name":"PranoSA/Samba_Project_Backends","owner":"PranoSA","description":null,"archived":false,"fork":false,"pushed_at":"2023-09-18T08:51:40.000Z","size":10486,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-14T02:09:19.738Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PranoSA.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-09-01T20:11:30.000Z","updated_at":"2023-09-01T20:50:30.000Z","dependencies_parsed_at":null,"dependency_job_id":"57615539-104b-4709-8b38-94532d7b889a","html_url":"https://github.com/PranoSA/Samba_Project_Backends","commit_stats":null,"previous_names":["pranosa/samba_project_backends"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PranoSA%2FSamba_Project_Backends","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PranoSA%2FSamba_Project_Backends/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PranoSA%2FSamba_Project_Backends/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PranoSA%2FSamba_Project_Backends/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PranoSA","download_url":"https://codeload.github.com/PranoSA/Samba_Project_Backends/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241692003,"owners_count":20004138,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-14T09:24:16.580Z","updated_at":"2026-05-23T16:34:04.754Z","avatar_url":"https://github.com/PranoSA.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Operation\n\n\nhttps://app.diagrams.net/#G1-ig-auPkGtmx-x2dDd2pt-YP4oedBp2J\n\n# Option Summary Guide\n\n\n## User Management / Authentication\n\nConfigure to store users in an LDAP directory and authenticate using a Bind operation or Kerberos, or\nConfigure to store users and authenticate using a Postgres Database with an md5 (hash on client), bcrypt, or Argon hashed passcode or \\\n\\\nConfigure to store users an authenticate using a DynamoDB Database with the same above hashes or \n\\\n\\\nConfigure to use an OIDC provider and Bearer token \n\\\n\nOIDC is generally reccommended for a public facing web app, LDAP is reccomended if you have an already existing LDAP database with customers and you want to provide this service, Postgres or DynamoDB is recomended if you want to manage your own datastore but want something that scales to the range of web users, DynamoDB if one wishes not to manage their own database.\n\n## Session Management\n\n\nConfigure to use OIDC provider Bearer tokens for Authentication or \\\n\nConfigure to use a Redis Database with sessions using cookies and CSRF tokens or\n\\\n\\\nConfigure to Use simple-auth header that re-authenticates using a username/passcode for each request\n\n\n## Administrative Backing Store Options\n\nThis section is to store stateful information about samba services, such as available file systems mounted on the samba servers, which backing servers exist on the cluster and at what IP, where the available file systems with available storage are that can mount a new share space, and replication regions. \n\nThe Database Tables (Or Entities) associated with this are \n\n### SambaServers\n    Stores Information About Which Server IDs exist at which IPs, \n\n### Spaces\n    Stores Information About Which Samba_Share Server a space resides, how much room is allocated to it, and owner\n    \n### Samba_Shares\n    Stores Information about Who Can Access the Samba Share, Which Space it Resides In. \n\n### ISCSIServerFileSystems\n    In The Case you are using an ISCSI target for backing samba server, you can run a client-server program on the samba server and ISCSI server respectively that enforces a level of consistency between them. \n\n\n### Options:\n1. ETCD (For Company Level Deployments)\n2. Postgres (For Web-Scale Level Deployments)\n3. DynamoDB (If you wish not to manage your own database)\n\n\n## Noun List \nList of Objects that will be referenced in the Code and Documentation \n\n### User : Globally Defined User\nGlobally Defined User to The Web Application\n\n\n### Samba User\nUser Defined with smbpasswd on a samba password, these credentials aren't cross-referenced anywhere, \nthe user name will be the ID of the samba Share + Login Name to the web application\n\n\n### Space : \nAllocated Space For a File System Identified by User.id + spaceid \n\n\n### Share :\n File System Share with an owner who allocates it through Web API\n\n\n### File-System: \nTracks File Systems Mounted on the Samba Share Servers (Backend Only)\n\n\n### ISCSI_FS_ID : \nTracks ISCSI Targets and Backup Replicas\n\n\n### Samba_Server :\n Tracks Samba Servers, Their IP Locations and Replicas\n\n\n### ISCSI_SERVER: (Might Remove)\nTracks ISCSI Targets, Their IP, ID, and Replicas\n\n\n# Deployment Options\n\n\n\n\u003cbr\u003e\n\n## Login/Signup Methods\n\nConfiguration Can Be Setup On Where to Store Usernames and their respective passwords (as well as the challenge hash to be done)\nto authenticate users and return credentials to the User to map to sessions.\n\nWhen using OIDC, this is done by the OIDC Provider where the client will have to use OIDC Configuration (Auth URL, ClientID or \nClientID + ClientSecret, Redirect URIs, Token Endpoints) to receive these credentials.\n\n\n\n### Allowing Signup with Postgres or DynamoDB\n\nTo allow creation of user store using a user table that stores a salted hash challenge row to authenticate against.\nThis allows Signup\n\n### LDAP\nExternally Managed LDAP search with a search base DN for users, allows authentication with attempted bind requests to the server.\n\n### OIDC / JWKS\nExternally Managed 0AUTH2 / OIDC Provider\n\u003cbr\u003e\n\n## Session Methods\n\nConfiguration to be setup to use different Modes of Authentication for HTTP Requests to the Web-Server Application\nThese will be used to assume roles within the application.\n\nThe Session methods involve either Authentication Headers in the Request or Authentication Cookies with a CSRF Token \nmapped against a Redis Database. \n\u003cbr\u003e\n\n### Basic Authentication\n\nAuthentication Header \"Basic\" +\" \" + base64(username):base64(string)\n\u003cbr\u003e\n\n### Cookie Based Authentication\n\nCookie with Name Authentication and HTTP-Only Access \nNeeds to Be configured with Domain Attribute \n\n\u003cbr\u003e\n### Bearer Token Authentication\n\nFor OIDC Tokens from the SSO Keycloak or other OIDC provider instance\n\nAuthentication Header \"Bearer\" + \" \" + id_token\n \n \u003cbr\u003e\n\n## Server Management Storage\n\nThis Will Be Database Tables To Be used to store information about \nSamba Hosts\nSamba File Systems\nSamba File Spaces\nSamba Shares / Groups / Invites\nand information about accesibility per user\n\n### Postgres\n\nA sample migration to setup the necessary tables for the Postgres Configuration are in this repository under the migration folder.\n\u003cbr\u003e\n\n### DynamoDB (Serverless)\n\nThis application will assume 3 DynamoDB Table Names \n1. Samba_Hosts -\u003e Stores Information about Hosts and Their File Systems and what Spaces Have been alocated to them\n2. Samba Spaces -\u003e Stores Information about Allocated Spaces and What Samba Shares Have Been Allocated To Them\n3. Samba Shares -\u003e Stores Information About Samba Shares, What space they live on, and invites and group members to those samba shares.\n\nThe recommended indexing for these tables are as follows:\nOther index names will not be searched against\n\n#### Samba_Hosts\nPrimary Key Index (Only Partition Key) on column hostid and no Global Secondary Index/\n\n#### Samba_Spaces\nPrimary Key Index (Only Partition Key) on column spaceid and Global Secondary Index with Only Partition Key fs_id\n\n#### Samba_Shares\nPrimary Key Index (Only Partition Key) on column shareid and Global Secondary Index (Partition Key Only) on space_id\n\n\n###  ETCD (Server Management Only) -\u003e STILL NEEDS TO BE IMPLEMENTED\n\n\n\u003cbr\u003e\n\n## User Storage (This Feature Doesn't Exist For Now )\n\n### Postgres\n\n### DynamoDB (Serverless)\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpranosa%2Fsamba_project_backends","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpranosa%2Fsamba_project_backends","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpranosa%2Fsamba_project_backends/lists"}