diff src/handle.rs @ 78:002adfb98c5c

Rename files, reorder structs, remove annoying BorrowedBinaryData type. This is basically a cleanup change. Also it adds tests. - Renames the files with Questions and Answers to question and answer. - Reorders the structs in those files to put the important ones first. - Removes the BorrowedBinaryData type. It was a bad idea all along. Instead, we just use (&[u8], u8). - Adds some tests because I just can't help myself.
author Paul Fisher <paul@pfish.zone>
date Sun, 08 Jun 2025 03:48:40 -0400
parents c30811b4afae
children 5aa1a010f1e8
line wrap: on
line diff
--- a/src/handle.rs	Sun Jun 08 01:03:46 2025 -0400
+++ b/src/handle.rs	Sun Jun 08 03:48:40 2025 -0400
@@ -209,18 +209,18 @@
     trait_item!(
         set = set_authtok_item,
         item = "PAM_AUTHTOK",
-        see = PamModuleHandle::authtok_item,
-        "Sets the user's authentication token (e.g., password)."
+        see = PamModuleOnly::authtok_item,
+        "Gets the user's authentication token (e.g., password)."
         ""
         "This is usually set automatically when "
-        "[`get_authtok`](PamModuleHandle::get_authtok) is called, "
+        "[`get_authtok`](PamModuleOnly::get_authtok) is called, "
         "but can be manually set."
     );
 
     trait_item!(
         set = set_old_authtok_item,
         item = "PAM_OLDAUTHTOK",
-        see = PamModuleHandle::old_authtok_item,
+        see = PamModuleOnly::old_authtok_item,
         "Sets the user's \"old authentication token\" when changing passwords."
         ""
         "This is usually set automatically by PAM."
@@ -308,7 +308,7 @@
     trait_item!(
         get = old_authtok_item,
         item = "PAM_OLDAUTHTOK",
-        see = PamHandle::set_old_authtok_item,
+        see = PamShared::set_old_authtok_item,
         "Gets the user's old authentication token when changing passwords."
         ""
         "This should only ever be called by *password-change* PAM modules."