The sync version of ldap3 0.7 does a block_on and as my trait implementation already run in Tokio executor (through warp) I would need to use spawn_blocking as suggested here but I'm wondering if there is a way to call the async version of ldap3 in my trait implementation so I won't block.
Short of completely changing oxide-auth's API, I don't think there's much we can do here. It exposes a fully synchronous interface and it'd be pretty hard to reach through that synchronous interface to perform an async operation. I mean, to do an await, the whole call stack up to the executor needs to be able to be stored in a Future so it can be paused and resumed. If everything's an async fn, then that just works. But if there's some layer which is fully synchronous, and doesn't allow returning a Future to poll, then there isn't really any way to transform that layer into a future besides straight up rewriting it, or writing an alternative.