mirror of
https://github.com/samba-team/samba.git
synced 2025-01-26 10:04:02 +03:00
lib: Add samlogon_cache.h
Move prototypes into its own header file Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
This commit is contained in:
parent
df63288d3a
commit
a55bd7e424
@ -28,6 +28,7 @@
|
|||||||
#include "passdb.h"
|
#include "passdb.h"
|
||||||
#include "libsmb/libsmb.h"
|
#include "libsmb/libsmb.h"
|
||||||
#include "libcli/auth/netlogon_creds_cli.h"
|
#include "libcli/auth/netlogon_creds_cli.h"
|
||||||
|
#include "libsmb/samlogon_cache.h"
|
||||||
|
|
||||||
#undef DBGC_CLASS
|
#undef DBGC_CLASS
|
||||||
#define DBGC_CLASS DBGC_AUTH
|
#define DBGC_CLASS DBGC_AUTH
|
||||||
|
@ -839,14 +839,6 @@ NTSTATUS remote_password_change(const char *remote_machine, const char *user_nam
|
|||||||
const char *old_passwd, const char *new_passwd,
|
const char *old_passwd, const char *new_passwd,
|
||||||
char **err_str);
|
char **err_str);
|
||||||
|
|
||||||
/* The following definitions come from libsmb/samlogon_cache.c */
|
|
||||||
|
|
||||||
bool netsamlogon_cache_init(void);
|
|
||||||
void netsamlogon_clear_cached_user(const struct dom_sid *user_sid);
|
|
||||||
bool netsamlogon_cache_store(const char *username, struct netr_SamInfo3 *info3);
|
|
||||||
struct netr_SamInfo3 *netsamlogon_cache_get(TALLOC_CTX *mem_ctx, const struct dom_sid *user_sid);
|
|
||||||
bool netsamlogon_cache_have(const struct dom_sid *user_sid);
|
|
||||||
|
|
||||||
/* The following definitions come from libsmb/smberr.c */
|
/* The following definitions come from libsmb/smberr.c */
|
||||||
|
|
||||||
const char *smb_dos_err_name(uint8_t e_class, uint16_t num);
|
const char *smb_dos_err_name(uint8_t e_class, uint16_t num);
|
||||||
|
@ -22,6 +22,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
|
#include "samlogon_cache.h"
|
||||||
#include "system/filesys.h"
|
#include "system/filesys.h"
|
||||||
#include "librpc/gen_ndr/ndr_krb5pac.h"
|
#include "librpc/gen_ndr/ndr_krb5pac.h"
|
||||||
#include "../libcli/security/security.h"
|
#include "../libcli/security/security.h"
|
||||||
|
41
source3/libsmb/samlogon_cache.h
Normal file
41
source3/libsmb/samlogon_cache.h
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
/*
|
||||||
|
* Unix SMB/CIFS implementation.
|
||||||
|
* Net_sam_logon info3 helpers
|
||||||
|
* Copyright (C) Alexander Bokovoy 2002.
|
||||||
|
* Copyright (C) Andrew Bartlett 2002.
|
||||||
|
* Copyright (C) Gerald Carter 2003.
|
||||||
|
* Copyright (C) Tim Potter 2003.
|
||||||
|
* Copyright (C) Guenther Deschner 2008.
|
||||||
|
*
|
||||||
|
* This program is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef __LIBSMB_SAMLOGON_CACHE_H__
|
||||||
|
#define __LIBSMB_SAMLOGON_CACHE_H__
|
||||||
|
|
||||||
|
#include "replace.h"
|
||||||
|
#include <talloc.h>
|
||||||
|
|
||||||
|
struct dom_sid;
|
||||||
|
struct netr_SamInfo3;
|
||||||
|
|
||||||
|
bool netsamlogon_cache_init(void);
|
||||||
|
void netsamlogon_clear_cached_user(const struct dom_sid *user_sid);
|
||||||
|
bool netsamlogon_cache_store(const char *username,
|
||||||
|
struct netr_SamInfo3 *info3);
|
||||||
|
struct netr_SamInfo3 *netsamlogon_cache_get(TALLOC_CTX *mem_ctx,
|
||||||
|
const struct dom_sid *user_sid);
|
||||||
|
bool netsamlogon_cache_have(const struct dom_sid *user_sid);
|
||||||
|
|
||||||
|
#endif
|
@ -43,6 +43,7 @@
|
|||||||
#include "source4/lib/messaging/messaging.h"
|
#include "source4/lib/messaging/messaging.h"
|
||||||
#include "lib/param/param.h"
|
#include "lib/param/param.h"
|
||||||
#include "lib/async_req/async_sock.h"
|
#include "lib/async_req/async_sock.h"
|
||||||
|
#include "libsmb/samlogon_cache.h"
|
||||||
|
|
||||||
#undef DBGC_CLASS
|
#undef DBGC_CLASS
|
||||||
#define DBGC_CLASS DBGC_WINBIND
|
#define DBGC_CLASS DBGC_WINBIND
|
||||||
|
@ -30,6 +30,7 @@
|
|||||||
#include "../libcli/ldap/ldap_ndr.h"
|
#include "../libcli/ldap/ldap_ndr.h"
|
||||||
#include "../libcli/security/security.h"
|
#include "../libcli/security/security.h"
|
||||||
#include "../libds/common/flag_mapping.h"
|
#include "../libds/common/flag_mapping.h"
|
||||||
|
#include "libsmb/samlogon_cache.h"
|
||||||
#include "passdb.h"
|
#include "passdb.h"
|
||||||
|
|
||||||
#ifdef HAVE_ADS
|
#ifdef HAVE_ADS
|
||||||
|
@ -34,6 +34,7 @@
|
|||||||
#include "../libcli/security/security.h"
|
#include "../libcli/security/security.h"
|
||||||
#include "passdb/machine_sid.h"
|
#include "passdb/machine_sid.h"
|
||||||
#include "util_tdb.h"
|
#include "util_tdb.h"
|
||||||
|
#include "libsmb/samlogon_cache.h"
|
||||||
|
|
||||||
#undef DBGC_CLASS
|
#undef DBGC_CLASS
|
||||||
#define DBGC_CLASS DBGC_WINBIND
|
#define DBGC_CLASS DBGC_WINBIND
|
||||||
|
@ -23,6 +23,7 @@
|
|||||||
#include "winbindd.h"
|
#include "winbindd.h"
|
||||||
#include "../libcli/auth/libcli_auth.h"
|
#include "../libcli/auth/libcli_auth.h"
|
||||||
#include "../libcli/security/security.h"
|
#include "../libcli/security/security.h"
|
||||||
|
#include "libsmb/samlogon_cache.h"
|
||||||
#undef DBGC_CLASS
|
#undef DBGC_CLASS
|
||||||
#define DBGC_CLASS DBGC_WINBIND
|
#define DBGC_CLASS DBGC_WINBIND
|
||||||
|
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
#include "rpc_client/cli_samr.h"
|
#include "rpc_client/cli_samr.h"
|
||||||
#include "rpc_client/cli_lsarpc.h"
|
#include "rpc_client/cli_lsarpc.h"
|
||||||
#include "../libcli/security/security.h"
|
#include "../libcli/security/security.h"
|
||||||
|
#include "libsmb/samlogon_cache.h"
|
||||||
|
|
||||||
#undef DBGC_CLASS
|
#undef DBGC_CLASS
|
||||||
#define DBGC_CLASS DBGC_WINBIND
|
#define DBGC_CLASS DBGC_WINBIND
|
||||||
|
@ -42,6 +42,7 @@
|
|||||||
#include "auth/gensec/gensec.h"
|
#include "auth/gensec/gensec.h"
|
||||||
#include "librpc/crypto/gse_krb5.h"
|
#include "librpc/crypto/gse_krb5.h"
|
||||||
#include "lib/afs/afs_funcs.h"
|
#include "lib/afs/afs_funcs.h"
|
||||||
|
#include "libsmb/samlogon_cache.h"
|
||||||
|
|
||||||
#undef DBGC_CLASS
|
#undef DBGC_CLASS
|
||||||
#define DBGC_CLASS DBGC_WINBIND
|
#define DBGC_CLASS DBGC_WINBIND
|
||||||
|
@ -30,6 +30,7 @@
|
|||||||
#include "source4/lib/messaging/messaging.h"
|
#include "source4/lib/messaging/messaging.h"
|
||||||
#include "librpc/gen_ndr/ndr_lsa.h"
|
#include "librpc/gen_ndr/ndr_lsa.h"
|
||||||
#include "auth/credentials/credentials.h"
|
#include "auth/credentials/credentials.h"
|
||||||
|
#include "libsmb/samlogon_cache.h"
|
||||||
|
|
||||||
#undef DBGC_CLASS
|
#undef DBGC_CLASS
|
||||||
#define DBGC_CLASS DBGC_WINBIND
|
#define DBGC_CLASS DBGC_WINBIND
|
||||||
|
Loading…
x
Reference in New Issue
Block a user