---
name: "gss_import_sec_context"
section: "3"
platform: "linux"
package: "gss-man"
version: "1.0.4-4"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/gss_import_sec_context"
---

# gss\_import\_sec\_context(3)

API function

## NAME

gss\_import\_sec\_context - API function

## SYNOPSIS

**#include \<gss.h\>**

**OM\_uint32 gss\_import\_sec\_context(OM\_uint32 \*** *minor\_status***, const gss\_buffer\_t** *interprocess\_token***, gss\_ctx\_id\_t \*** *context\_handle***);**

## ARGUMENTS

- OM\_uint32 \* minor\_status

  (Integer, modify) Mechanism specific status code.

- const gss\_buffer\_t interprocess\_token

  (buffer, opaque, modify) Token received from\
     exporting process

- gss\_ctx\_id\_t \* context\_handle

  (gss\_ctx\_id\_t, modify) Context handle of newly\
     reactivated context.  Resources associated with this context\
     handle must be released by the application after use with a call\
     to **gss\_delete\_sec\_context()**.

## DESCRIPTION

Allows a process to import a security context established by another process.  A given interprocess token may be imported only once.  See gss\_export\_sec\_context.

## RETURN VALUE

\`GSS\_S\_COMPLETE\`: Successful completion.

\`GSS\_S\_NO\_CONTEXT\`: The token did not contain a valid context reference.

\`GSS\_S\_DEFECTIVE\_TOKEN\`: The token was invalid.

\`GSS\_S\_UNAVAILABLE\`: The operation is unavailable.

\`GSS\_S\_UNAUTHORIZED\`: Local policy prevents the import of this\
  context by the current process.

## REPORTING BUGS

Report bugs to \<bug-gss@gnu.org\>. GNU Generic Security Service home page: http://www.gnu.org/software/gss/ General help using GNU software: http://www.gnu.org/gethelp/

## COPYRIGHT

Copyright © 2003-2022 Simon Josefsson.\
 Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved.

## SEE ALSO

The full documentation for **gss** is maintained as a Texinfo manual.  If the **info** and **gss** programs are properly installed at your site, the command

-

  **info gss**

should give you access to the complete manual.
