---
name: "rpc_gss_mech_to_oid"
section: "3t"
platform: "linux"
package: "libtirpc"
version: "1.3.8-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/rpc_gss_mech_to_oid/3t"
---

# rpc\_gss\_mech\_to\_oid(3t)

Convert a mechanism name to a GSS-API oid

## NAME

**rpc\_gss\_mech\_to\_oid** – Convert a mechanism name to a GSS-API oid

## SYNOPSIS

**#include \<rpc/rpcsec\_gss.h\>**

*bool\_t*\

**rpc\_gss\_mech\_to\_oid**(*const char \*mech*, *gss\_OID \*oid\_ret*);

## DESCRIPTION

This function returns the GSS OID associated with the GSS\_API mechanism "mech".

## PARAMETERS

- mech

  The name of a GSS\_API mechanism. "kerberos\_v5" is currently the only supported mechanism.

- oid\_ret

  Buffer in which to place the returned OID

## RETURN VALUES

If the GSS\_API mechanism name is recognized, TRUE is returned. The corresponding GSS-API oid is returned in *\*oid\_ret*. Otherwise FALSE is returned and *\*oid\_ret* is left untouched.

## AVAILABILITY

The **rpc\_gss\_mech\_to\_oid**() function is part of libtirpc.

## SEE ALSO

[rpc(3)](/rpc/3.md), [gssapi(3)](/gssapi/3.md), [rpcsec\_gss(3)](/rpcsec_gss/3.md)

## AUTHORS

This manual page was written by Doug Rabson ⟨dfr@FreeBSD.org⟩.
