New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

workfront-cookie

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

workfront-cookie

Extracts values from workfront cookies

latest
Source
npmnpm
Version
3.4.5
Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

NPM version NPM downloads Dependencies Dev. Dependencies MIT License Build Status Coverage

Provides methods for extracting values from workfront cookies.

Installation

Via NPM:

npm i workfront-cookie --save-dev

Package provides UMD bundle, so you can also include it to your page using <script> tag.

In that case a global variable called WorkfrontCookie will be created.

API

Bundle exposes an object with the following items:

A constant string representing name of the Workfront cookie.

getSessionID(cookieString?: string): undefined | string

Returns Workfront session ID currently stored in the cookie.

In case the second argument is specified, value will be extracted from that string instead of using document.cookie.

If for some reason it is impossible to determine session ID, this method will return undefined.

getXSRFToken(cookieString?: string): undefined | string

Returns Workfront XSRF token currently stored in the cookie. Eventually, this token will replace sessionID.

In case the second argument is specified, value will be extracted from that string instead of using document.cookie.

If for some reason it is impossible to determine XSRF token, this method will return undefined.

readCookie(name: string, cookieString?: string): undefined | string

Returns value for the given key (name) stored in cookie.

It case the second argument is specified, value will be extracted from that string instead of using document.cookie.

License

MIT (http://www.opensource.org/licenses/mit-license.php)

Keywords

Workfront

FAQs

Package last updated on 20 Sep 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts