# getEncodedCrl

## Content

# Function: getEncodedCrl()

```ts
function getEncodedCrl(crlUrl, options?): Promise<ArrayBuffer>;
```

Retrieves and returns an encoded Certificate Revocation List (CRL) from the specified URL.

This function fetches a CRL using either a custom fetch callback or the default PDF fetch method.
The CRL is returned as an ArrayBuffer containing the raw binary data, or null if the CRL cannot be retrieved.

## Parameters

### crlUrl

`string`

The URL of the Certificate Revocation List to fetch

### options?

[`ExternalResourcesOptions`](../interfaces/ExternalResourcesOptions)

The options used to execute OCSP request.

## Returns

`Promise`&lt;`ArrayBuffer`&gt;

A promise that resolves to an ArrayBuffer containing the encoded CRL data,
         or null if the CRL cannot be retrieved or doesn't exist
