diff --git a/Cargo.toml b/Cargo.toml
index f407f3a6f671444d06568fd8063a0fb404f9da3a..a56e8de4d7a9e4f2eb99a825f6f1bbb0bcf2f9e4 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -14,7 +14,7 @@ crate-type = [ "cdylib" ]
 
 [dependencies]
 pamsm = { version = "^0.4.2", features = ["libpam"] }
-libnss = "^0.1.0"
+libnss = "^0.4.0"
 paste = "^0.1"
 libc = "^0.2.0"
 lazy_static = "^1.3.0"
diff --git a/src/nss.rs b/src/nss.rs
index c321cb86cdad26454d9f9698fb9daf5546a366a4..ea6fdb7bc1b2572fac38a530f4ff5284384eaccf 100644
--- a/src/nss.rs
+++ b/src/nss.rs
@@ -49,7 +49,7 @@ fn nss_hook_prepare() -> Config {
     return conf;
 }
 
-fn get_bearer_token(config: Config) -> Result<String, Response> {
+fn get_bearer_token<T>(config: Config) -> Result<String, Response<T>> {
     let client_id = ClientId::new(get_or_error(&config, "nss.client_id", Response::Unavail)?);
     let client_secret = match get_optional(&config, "nss.client_secret") {
         Some(v) => Some(ClientSecret::new(v)),
@@ -82,7 +82,7 @@ fn get_bearer_token(config: Config) -> Result<String, Response> {
     let result = request.request(http_client);
 
     match result {
-            Ok(t) => Ok(t),
+            Ok(t) => Ok("".to_string()),
             Err(e) => match e {
                 RequestTokenError::Request(re) => match re {
                     reqwest::Error::Reqwest(ree) => {
@@ -118,32 +118,35 @@ fn get_bearer_token(config: Config) -> Result<String, Response> {
         }
 }
 
-fn do_json_request(config: Config, url: String) -> Result<String, Response> {
+fn do_json_request<T>(config: Config, url: String) -> Result<String, Response<T>> {
     let token = get_bearer_token(config)?;
+    Ok("".to_string())
 }
 
 struct OidcPasswd;
 
 impl PasswdHooks for OidcPasswd {
-    fn get_all_entries() -> Vec<Passwd> {
+    fn get_all_entries() -> Response<Vec<Passwd>> {
         let config = nss_hook_prepare();
 
-        vec![
-            Passwd {
-                name: "test".to_string(),
-                passwd: "x".to_string(),
-                uid: 1005,
-                gid: 1005,
-                gecos: "Test Account".to_string(),
-                dir: "/home/test".to_string(),
-                shell: "/bin/bash".to_string(),
-            }
-        ]
+        Response::Success(
+            vec![
+                Passwd {
+                    name: "test".to_string(),
+                    passwd: "x".to_string(),
+                    uid: 1005,
+                    gid: 1005,
+                    gecos: "Test Account".to_string(),
+                    dir: "/home/test".to_string(),
+                    shell: "/bin/bash".to_string(),
+                }
+            ]
+        )
     }
 
-    fn get_entry_by_uid(uid: libc::uid_t) -> Option<Passwd> {
+    fn get_entry_by_uid(uid: libc::uid_t) -> Response<Passwd> {
         if uid == 1005 {
-            return Some(Passwd {
+            return Response::Success(Passwd {
                 name: "test".to_string(),
                 passwd: "x".to_string(),
                 uid: 1005,
@@ -154,12 +157,12 @@ impl PasswdHooks for OidcPasswd {
             });
         }
 
-        None
+        Response::NotFound
     }
 
-    fn get_entry_by_name(name: String) -> Option<Passwd> {
+    fn get_entry_by_name(name: String) -> Response<Passwd> {
         if name == "test" {
-            return Some(Passwd {
+            return Response::Success(Passwd {
                 name: "test".to_string(),
                 passwd: "x".to_string(),
                 uid: 1005,
@@ -170,7 +173,7 @@ impl PasswdHooks for OidcPasswd {
             });
         }
 
-        None
+        Response::NotFound
     }
 }