{"id":13508396,"url":"https://github.com/namjaejeon/ksmbd","last_synced_at":"2025-10-25T03:45:47.979Z","repository":{"id":38212215,"uuid":"48567004","full_name":"namjaejeon/ksmbd","owner":"namjaejeon","description":"ksmbd kernel server(SMB/CIFS server)","archived":false,"fork":false,"pushed_at":"2024-08-12T02:58:27.000Z","size":7018,"stargazers_count":266,"open_issues_count":28,"forks_count":62,"subscribers_count":15,"default_branch":"master","last_synced_at":"2024-08-13T20:17:07.693Z","etag":null,"topics":["cifs","file-server","filesystem","in-kernel","linux","network","network-file-system","performance","rdma","server","smb","smb3"],"latest_commit_sha":null,"homepage":"https://github.com/cifsd-team/ksmbd","language":"C","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/namjaejeon.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":"2015-12-25T04:54:16.000Z","updated_at":"2024-08-13T20:17:16.325Z","dependencies_parsed_at":"2023-10-15T00:19:32.422Z","dependency_job_id":"e587b67e-ab59-49fd-98dd-53fd38cb8aba","html_url":"https://github.com/namjaejeon/ksmbd","commit_stats":null,"previous_names":["namjaejeon/cifsd"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/namjaejeon%2Fksmbd","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/namjaejeon%2Fksmbd/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/namjaejeon%2Fksmbd/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/namjaejeon%2Fksmbd/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/namjaejeon","download_url":"https://codeload.github.com/namjaejeon/ksmbd/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246314011,"owners_count":20757450,"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":["cifs","file-server","filesystem","in-kernel","linux","network","network-file-system","performance","rdma","server","smb","smb3"],"created_at":"2024-08-01T02:00:52.492Z","updated_at":"2025-10-25T03:45:42.948Z","avatar_url":"https://github.com/namjaejeon.png","language":"C","funding_links":[],"categories":["C","server"],"sub_categories":[],"readme":"\n# Content\n\n- [What is KSMBD?](#KSMBDwhat-is-ksmbd)\n- [Under PFIF](#under-pfif)\n- [Git](#git)\n- [Maintainers](#maintainers)\n- [Bug reports or contribution](#Bug-reports-or-contribution)\n- [Features](#features)\n- [Supported Linux Kernel Versions](#supported-linux-kernel-versions)\n- [KSMBD architecture](#ksmbd-architecture)\n\n\n## What is KSMBD?\n\nKSMBD is an opensource In-kernel CIFS/SMB3 server created by Namjae Jeon for Linux Kernel. It's an implementation of SMB/CIFS protocol in kernel space for sharing files and IPC services over network. Initially the target is to provide improved file I/O performances, but the bigger goal is to have some new features which are much easier to develop and maintain inside the kernel and expose the layers fully. Directions can be attributed to sections where SAMBA is moving to few modules inside the kernel to have features like RDMA(Remote direct memory access) to work with actual performance gain.\n\n\n## Under PFIF\n\nThis code was developed in participation with the Protocol Freedom Information Foundation.\n\nPlease see\n* http://samba.org/samba/PFIF/\nfor more details.\n\n\n## Git\n\nThe development git tree is available at\n* https://github.com/cifsd-team/ksmbd\n* https://github.com/cifsd-team/ksmbd-tools\n\n\n## Maintainers\n\n* Namjae Jeon \u003clinkinjeon@kernel.org\u003e\n\n\n## Bug reports or contribution\n\nFor reporting bugs and sending patches, please send the patches to the following mail address:\n\n* linkinjeon@kernel.org\n\nor open issues/send PRs to [KSMBD](https://github.com/cifsd-team/ksmbd).\n\n## Installing as a stand-alone module\n\nInstall prerequisite package for Fedora, RHEL:\n```\n\tyum install kernel-devel-$(uname -r)\n```\n\nBuild step:\n```\n\tmake\n\tsudo make install\n```\n\nTo load the driver manually, run this as root:\n```\n\tmodprobe ksmbd\n```\n\n\n## Installing as a part of the kernel\n\n1. Let's take [linux] as the path to your kernel source dir.\n```\n\tcd [linux]\n\tcp -ar ksmbd [linux]/fs/\n```\n\n2. edit [linux]/fs/Kconfig\n```\n\tsource \"fs/cifs/Kconfig\"\n\t+source \"fs/ksmbd/Kconfig\"\n\tsource \"fs/coda/Kconfig\"\n```\n\n3. edit [linux]/fs/Makefile\n```\n\tobj-$(CONFIG_CIFS)              += cifs/\n\t+obj-$(CONFIG_SMB_SERVER)       += ksmbd/\n\tobj-$(CONFIG_HPFS_FS)           += hpfs/\n```\n4. make menuconfig and set ksmbd\n```\n\t[*] Network File Systems  ---\u003e\n\t\t\u003cM\u003e   SMB server support\n```\n\nbuild your kernel\n\n\n## Features\n\n*Implemented*\n1. SMB1(CIFS), SMB2/3 protocols for basic file sharing\n2. Dynamic crediting\n3. Compound requests\n4. oplock/lease\n5. Large MTU\n6. NTLM/NTLMv2\n7. Auto negotiation\n8. HMAC-SHA256 Signing\n9. Secure negotiate\n10. Signing Update\n11. Pre-authentication integrity(SMB 3.1.1)\n12. SMB3 encryption(CCM, GCM)\n13. SMB direct(RDMA)\n14. Win-ACL\n15. Kerberos\n16. Multi-channel\n\n*Planned*\n1. Durable handle v1/v2\n2. Persistent handles\n3. Directory lease\n\n\n## Supported Linux Kernel Versions\n\n* Linux Kernel 5.4 or later\n\n\n## KSMBD architecture\n\n```\n               |--- ...\n       --------|--- ksmbd/3 - Client 3\n       |-------|--- ksmbd/2 - Client 2\n       |       |         _____________________________________________________\n       |       |        |- Client 1                                           |\n\u003c--- Socket ---|--- ksmbd/1   \u003c\u003c= Authentication : NTLM/NTLM2, Kerberos(TODO)|\n       |       |      | |      \u003c\u003c= SMB : SMB1, SMB2, SMB2.1, SMB3, SMB3.0.2,  |\n       |       |      | |                SMB3.1.1                             |\n       |       |      | |_____________________________________________________|\n       |       |      |\n       |       |      |--- VFS --- Local Filesystem\n       |       |\nKERNEL |--- ksmbd/0(forker kthread)\n---------------||---------------------------------------------------------------\nUSER           ||\n               || communication using NETLINK\n               ||  ______________________________________________\n               || |                                              |\n        ksmbd.mountd \u003c\u003c= DCE/RPC, WINREG                         |\n               ^  |  \u003c\u003c= configure shares setting, user accounts |\n               |  |______________________________________________|\n               |\n               |------ smb.conf(config file)\n               |\n               |------ ksmbdpwd.db(user account/password file)\n                            ^\n  ksmbd.adduser ---------------|\n\n```\n\n## Performance\n\n1. ksmbd vs samba performance comparison using iozone (Linux Client)\n\u003cbr/\u003e\u003cbr/\u003e\u003cimg src=\"https://github.com/cifsd-team/cifsd-perf/blob/master/4k_read-write_performance.PNG\"  width=\"850\" height=\"450\"\u003e\n\n2. ksmbd vs samba performance comparison using fileop (Linux Client)\n\u003cbr/\u003e\u003cbr/\u003e\u003cimg src=\"https://github.com/cifsd-team/cifsd-perf/blob/master/Fileop_throughput_Performance.PNG\"  width=\"850\" height=\"450\"\u003e\n\n3. ksmbd vs samba performance comparison using CrystalDiskMark (Windows Client)\n\u003cbr/\u003e\u003cbr/\u003e![CrystalDiskMark](https://github.com/cifsd-team/cifsd-perf/blob/master/CrystalDiskMark_Performance.JPG)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnamjaejeon%2Fksmbd","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnamjaejeon%2Fksmbd","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnamjaejeon%2Fksmbd/lists"}