Commit graph

688 commits

Author SHA1 Message Date
Firstyear 1791f12adf
Oauth2 ui flows (#527) 2021-07-25 10:51:37 +10:00
Firstyear ea080feac8
Update webauthn-rs to alpha.9 (#532) 2021-07-24 14:58:38 +10:00
James Hodgkinson 7997864187
Prompting user for their username when multiple tokens exist (#525) 2021-07-13 08:46:45 +10:00
James Hodgkinson fc2824eec5
fixing restores on #456 (#519) 2021-07-08 10:09:15 +10:00
William Brown 4be329e946 (cargo-release) version 1.1.0-alpha.5 2021-07-07 12:04:12 +10:00
William Brown e5e760b109 Release prep 2021-07-07 12:02:46 +10:00
Firstyear 4c6a28b7ad
511 upgrade failure - add debuging tools and improve debugging of the issue. (#512) 2021-07-01 14:51:25 +10:00
Firstyear 1de1b2db3b
Add the ability to configure and provide Oauth2 authentication for Kanidm. (#485) 2021-06-29 14:23:39 +10:00
Firstyear 35d32bc5dd
Update webauthn-authenticator-rs to fix test failures (#493) 2021-06-26 11:47:21 +10:00
Firstyear f5e2295319
20210607 orca ldap (#470) 2021-06-17 13:53:23 +10:00
Firstyear ea34dc08a9
Add email syntax (#465)
Part one of #461 - this adds the syntax to support email addresses and validation of their content, and a method to serialise to the DB that can be extended with attribute tagging in the future. Part two will address administration of these values.
2021-06-12 10:01:44 +10:00
Firstyear e8b1089bfd
414 clear stale credentials (#447) 2021-05-26 16:11:00 +10:00
Firstyear 6901a5a545
Orca - a load testing framework for Kanidm (#431) 2021-05-06 21:15:12 +10:00
Firstyear 644eb0b0d6
Add verification of name indexes (#433) 2021-05-06 21:12:02 +10:00
Firstyear 8da89613e3
Rough working login page (#417) 2021-04-24 10:53:19 +10:00
Firstyear 72dfe1b035
Idlset2, query cache, acp resolve cache (#409) 2021-04-14 09:56:40 +10:00
William Brown 0ac5da855f (cargo-release) version 1.1.0-alpha.4 2021-04-01 10:29:22 +10:00
William Brown c95ce71fcb (cargo-release) version 1.1.0-alpha.4 2021-04-01 10:29:22 +10:00
William Brown ce0f10cd95 (cargo-release) version 1.1.0-alpha.4 2021-04-01 10:29:22 +10:00
William Brown 6152b7ae14 (cargo-release) version 1.1.0-alpha.4 2021-04-01 10:29:21 +10:00
William Brown dc3588a2c2 (cargo-release) version 1.1.0-alpha.4 2021-04-01 10:29:21 +10:00
William Brown e8554073a3 (cargo-release) version 1.1.0-alpha.4 2021-04-01 10:29:21 +10:00
William Brown b3b48b6c43 (cargo-release) version 1.1.0-alpha.4 2021-04-01 10:29:20 +10:00
William Brown 3b6be9aaf2 (cargo-release) version 1.1.0-alpha.4 2021-04-01 10:29:20 +10:00
William Brown 9bf4b0f052 Release Prep 2021-04-01 10:29:09 +10:00
Firstyear 988944a085
Add auth session header type (#398) 2021-04-01 07:14:15 +10:00
Firstyear 6bc719cdb2
Base web UI (#391)
Initial web ui (not-functional yet)
2021-03-26 11:22:00 +10:00
William Brown e1cbd325a5 Update sshkeys to resolve ssh issue 2021-03-15 10:20:54 +10:00
Firstyear adb3f819ba
Add the unixd tasks daemon (#349)
Fixes #180 - this adds an oddjobd style tasks daemon to the unix tools. This supports creation of home directories and the maintenance of alias symlinks to these allowing user renames. The tasks daemon is written to require root, but is seperate from the unixd daemon. Communication is via a root-only unix socket that the task daemon connects into to reduce the possibility of exploit.

Fixes #369 due to the changes to call_daemon_blocking
2021-03-13 12:33:15 +10:00
Firstyear d2ca2c5bc9
Fix pattern to match substr from ldap (#372) 2021-03-12 10:11:12 +10:00
William Brown 483aa6f23d Update build 2021-02-17 18:49:03 +10:00
Firstyear c416bc19df
Automatically create .cache if it doesn't exist. (#355) 2021-02-11 22:32:31 +10:00
Firstyear d745b15768
Use jemallocator in main server (#353) 2021-02-10 15:08:22 +10:00
Firstyear 8006142c9e
202 totp cli enrollment (#348)
Fixes #202 - This adds support for enrolling and removing totp on the cli, as well as a rebuilt work flow for login to allow dynamic prompting of what credetials are required.
2021-02-08 13:31:31 +10:00
Firstyear f4e31f1bb9
Improve idl behaviour (#342) 2021-01-28 09:50:43 +10:00
Firstyear 3844aadf60
Tokio1.0 (#340)
Upgrade dependencies, with the major highlight as the upgrade to tokio 1.0
2021-01-10 13:41:56 +10:00
Firstyear faa4b74683
320 filter double verify (#339)
Fixes #320, remove double verification of filters. In addition this replaces attr strings with smartstring to allow better inling due to their static and compact nature.
2020-12-30 09:53:19 +10:00
William Brown b34c8935ea (cargo-release) version 1.1.0-alpha.3 2020-12-28 09:51:17 +10:00
William Brown 3582199e70 (cargo-release) version 1.1.0-alpha.3 2020-12-28 09:51:16 +10:00
William Brown eaff53bf40 (cargo-release) version 1.1.0-alpha.3 2020-12-28 09:51:16 +10:00
William Brown 9e536e9202 (cargo-release) version 1.1.0-alpha.3 2020-12-28 09:51:16 +10:00
William Brown 3dfd9a0a81 (cargo-release) version 1.1.0-alpha.3 2020-12-28 09:51:16 +10:00
William Brown df441769ec (cargo-release) version 1.1.0-alpha.3 2020-12-28 09:51:15 +10:00
William Brown abb6c8201b (cargo-release) version 1.1.0-alpha.3 2020-12-28 09:51:15 +10:00
William Brown 41b739fe95 Update Dependencies 2020-12-28 09:45:44 +10:00
Firstyear 9dbb5ccb59
Unixd - NXCache of unknown items (#338)
Previously we would only cache "hits" - items that kanidm is aware
of and did know about. However, this mean querying a raw uid/gid
number that was not known to files or kanidm would result in kanidm
doing an online check each request.

This adds a NXcache to cache misses, so they can be served as misses,
faster, and to reduce load on the main kanidm servers.

Fixes #336
2020-12-28 09:41:16 +10:00
Firstyear ebdb57bbe7
WIP - Improve Auth Proto to Support Webauthn (#333)
This is a rewrite of the "on the wire" json for auth. This is a breaking change required to allow webauthn to work given limitations within Webauthn as a standard and how mixed credentials are challenged for.
2020-12-26 13:58:32 +10:00
Firstyear ec48edac82
13 135 webauthn support (#332)
Fixes #13 and Fixes #135 - webauthn and webauthn with cli. This is the core of webauthn, but only as a single factor. Some changes are still needed for webauthn as MFA and as a verified single factor. This will be made in a subsequent PR.
2020-12-02 11:12:07 +10:00
Firstyear 1a57aa9ea0
Fixes #324 account softlocking and rate limiting (#326)
This provides bruteforce protection and ratelimiting to stop
classes of attacks. This impacts all areas where a password or
authentication is performed (unix, ldap, auth).
2020-10-22 14:40:31 +10:00
Firstyear 018039b0b2
Account valid-from and expiry (#322)
Fixes #59 account policy and lockout. This is achived with a valid_from and expire attribute that are timestamps. Cli tools are added to manage these.
2020-10-10 10:31:51 +10:00
William Brown 229fe1b61c (cargo-release) version 1.1.0-alpha.2 2020-10-01 10:04:27 +10:00
William Brown 746af9c18f (cargo-release) version 1.1.0-alpha.2 2020-10-01 10:04:26 +10:00
William Brown ea0be21f4f (cargo-release) version 1.1.0-alpha.2 2020-10-01 10:04:26 +10:00
William Brown d2fab0659c (cargo-release) version 1.1.0-alpha.2 2020-10-01 10:04:26 +10:00
William Brown b62443a38f (cargo-release) version 1.1.0-alpha.2 2020-10-01 10:04:26 +10:00
William Brown 3e4926070b (cargo-release) version 1.1.0-alpha.2 2020-10-01 10:04:25 +10:00
William Brown 7837febabe (cargo-release) version 1.1.0-alpha.2 2020-10-01 10:04:25 +10:00
William Brown f4ccbfcaf7 Update Release Notes 2020-10-01 10:01:08 +10:00
Firstyear 4bf8ef72d5
250 cookie to auth bearer (#321)
Fixes #250, replacing cookies with auth-bearer tokens. This is done using fernet with randomised keys each startup. The reason for this is that in the future the size of the auth token may exceed cookie limits, so we must be able to understand and process auth bearer. Additionaly, this lets us store the tokens for say the kanidm cli as reqwest today can't persist a cookie jar.
2020-09-18 13:19:57 +10:00
Firstyear 29566b8f99
259 reduce clones (#319)
Fixes #259. Thanks to the linked worked example, we can reduce a problematic set of clones during filter metadata injection. Previously we had to create a new hashset every time we went to resolve index metadata in queries, but with this change we can now just use the copy-on-write hashset instead. This will improve cache access, reduces clones, and more. In a cargo test run this takes out nearly 15% of the execution time (on my system reducing the test time by nearly 35 seconds).

https://github.com/sunshowers/borrow-complex-key-example/blob/master/src/lib.rs
2020-09-11 12:39:05 +10:00
Firstyear bab44028f1
Xxx clippy outdated (#318)
This finishes some of the outstanding clippy issues that existed. Additionally, we updated all the project deps and updated libraries we could in the project. A bug exists currently in cargo outdated that is preventing further updates to this however, but that's a bit out of my hands.
2020-09-08 12:46:10 +10:00
Firstyear 0041445b73
314 improve async (#316)
this completely removes actix and actix-web from the codebase, replacing it with tokio and http-rs/tide. Due to a current temporary limit in tokio parts with openssl/libressl, rustls is used for the webserver, but I'll change this back once that issue is resolved. For now there are likely some other clippy issues, but the next step now is that I can finally run cargo outdated and update this and the other kanidm/* deps to be up to date due to no longer being held back on versions by actix. So following this, I need to finish clippy warnings, and run cargo outdated and cargo audit.
2020-09-06 08:44:35 +10:00
Firstyear dbfe87e675
On login pw upgrade (#315)
Fixes #295 on login pw upgrade. This adds support for SSHA512 to be imported at the request of @colbyprior, and adds a delayed action queue so that events can be run after-the-fact so that authentication does not need to exist under the write path.
2020-08-24 12:15:21 +10:00
William Brown 85ec82832e V large cleanup 2020-08-05 09:58:49 +10:00
William Brown c4805d2915 Improve server hardening
This adds a number of warnings to the server to help administrators make
better informed decisions about the security of their environment.
2020-07-31 14:55:14 +10:00
William Brown cdd7e0e49a Update deps + add simd support in container 2020-07-24 17:38:59 +10:00
William Brown fe1747c2bf Add FAQ + eap selection 2020-07-17 18:53:47 +10:00
Firstyear c8ac4970d8
Release Prep (#283) 2020-06-30 14:58:35 +10:00
Firstyear 96e6c9107d
refint improve (#274)
Fixes #61 and fixes #234 - this rewrites quite a few internals of refint and memberof to make them much more efficient compared to previously. This takes nearly 70s out of the test execution time - a full 25% of the run time of tests.

A number of other improvements have been made through out with regard to memory pre-alloc for hashset/hashmap, fixing some more types, and reducing some un-needed allocations.
2020-06-26 11:36:37 +10:00
Firstyear 0adec0d437
260 entry ava interfaces (#271)
Fixes #260 fixes #257 fixes #157. This is really a set of cleanups around the code base to minimise clones, choose better datastructures for specific tasks, improve the ability to pass references in certain calls and more. Generally this just makes everything a bit smoother, and really has big gains on the write path (it's about 20% faster now).
2020-06-24 21:17:46 +10:00
Firstyear 9aa03906f8
181 pam nsswitch name spn (#270)
This allows configuration of which attribute is presented during gid/uid resolution, adds home directory prefixing, and home directory name attribute selection.
2020-06-21 21:57:48 +10:00
Firstyear 0b15477ef4
212 262 db idl fixes (#269)
Fixes #212 and Fixes #262. This is largely a performance improvement and security improvement to how the databases are handled. The major cases are create/modify/reindex performance,
2020-06-19 10:00:54 +10:00
Firstyear fec28e03e2
195 rel cleanup (#268)
Fixes #195 pre release cleanup. This does a LOT, clippy, formatting, and much much more. It fixes a lot of parts of the book, improves server config and more.
2020-06-18 10:30:42 +10:00
Firstyear 70fa17f3a1
199 ldap gateway (#246)
adds an LDAP gateway to the server. It supports TLS if configured for the webserver, using the same parameters. It is a read only interface, only supporting bind via the configured posix password.
2020-06-10 12:07:43 +10:00
Firstyear 4bed9c87bf
Improve errors, tagging, logging and more across the codebase. (#243) 2020-06-05 14:01:20 +10:00
Firstyear 5eb370bc43
Phase 2, logging refactor (#236)
* Phase 2, logging refactor
2020-05-22 17:03:42 +10:00
Firstyear 16267e8a29
In progress logging design (#231) 2020-05-15 12:23:36 +10:00
Pando85 2670b6ae83 CI update all kanidm component version and tag
Add make entry to have all cargo versions updated from VERSION file.
Add `tag_version` github action to update all cargo.toml and tag it and
push it.
Remove cargo fmt check from CI because we have problems with different
versions and fails continually. Instead, we use cargo-husky to ensure
that all people run it automatically in its local, but this is not
obligatory.
Update to version 1.0.0-rc10, according to packages published.

In future cargo will support managing all dependencies from main
Cargo.toml. Ref: https://github.com/rust-lang/cargo/issues/3931

Resolve #225
2020-05-13 15:56:44 +10:00
Firstyear 15bc8d4120
101 idlcache (#224)
Fixes #101, concurrent caching of IDL and Entries. This yields a 10% improvement for test case execution, and 35% for tests run under --release mode. A lot of code around the code base was needed to be touched due to the extra need for mut in some operations and some lifetimes, but the majority of the work was in idl_arc_sqlite.rs, which has the cache layer. There are many performance gains yet to see, but most of those will come through improvement of the concread ARC and it's related BTree implementation.
2020-05-11 21:12:32 +10:00
Pando85 c2f77a47f3 Create light images with static binaries
- Change base builder image to `ekidd/rust-musl-builder` for create static
binaries.
- Add two flavours: alpine and stand alone binary.
- Add makefile commands for build, test and push kanidmd images and
  refactor previous code.
- Add missing things to `.dockerignore`.
- Refactor CI to use Makefile.
2020-05-06 11:07:01 +10:00
Pando85 d6acffd869 Fix sqlite fails in CI tests and fmt error
Add `libsqlite3-sys` crate to avoid sqlite3 missmatching version.

From [https://lib.rs/crates/libsqlite3-sys](https://lib.rs/crates/libsqlite3-sys)
> If you use the bundled feature, libsqlite3-sys will use the cc crate to compile SQLite from source and link against that. This source is embedded in the libsqlite3-sys crate and is currently SQLite 3.30.1 (as of rusqlite 0.21.0 / libsqlite3-sys 0.17.0). This is probably the simplest solution to any build problems.

Remove sqlite OS packages dependencies for build.

Also, we fix a format error to allow CI tests to pass again.
2020-05-06 10:16:26 +10:00
William Brown b8f906ed36 Update outdated libraries and add helper make argument. 2020-04-11 10:48:34 +10:00
Firstyear 8cfa8f3f95
12 totp (#201)
Implements #12, TOTP. This adds support for TOTP to the api and server, with server side token generation, authentication and the correct URI for encoding into QR codes for client token addition. Some extra measures have been taken such as in the stepped auth to always notify on the success or failure of the TOTP first (regardless of order) to prevent PW bruteforce attacks.
2020-04-10 15:50:45 +10:00
Firstyear ceb6048bf0
122 password import design (#196)
Implements #122 password import. This adds most of the server core framework to allow password imports from other sources, with new types easily able to be added in credential.rs.
2020-03-27 08:27:07 +10:00
William Brown 32dcaa39ac Test perf improvements 2020-03-26 11:56:20 +10:00
Firstyear c5664988e3
Refactor for actix and futures upgrade (#190) 2020-03-07 10:49:39 +10:00
Firstyear 5a9ad39d6b
20200218 pam (#189)
Add support for unix_password handling, and pam authentication for services.
2020-02-29 14:02:14 +10:00
Firstyear 9de7d33293
129 nsswitch stage 2 groups (#185)
Implements #129, adding the libnss_kanidm.so/dylib, and the related caching parts for properly handling these types.
2020-02-15 10:57:25 +10:30