
Research
Namastex.ai npm Packages Hit with TeamPCP-Style CanisterWorm Malware
Malicious Namastex.ai npm packages appear to replicate TeamPCP-style Canister Worm tradecraft, including exfiltration and self-propagation.
@ministryofjustice/hmpps-non-associations-api
Advanced tools
This library is designed to be used by DPS/HMPPS front-end applications that are based on hmpps-typescript-template and need to access the non-associations api.
Typescript applications can install the library in several ways:
This is the simplest method.
npm install --save @ministryofjustice/hmpps-non-associations-api
Pros:
Cons:
This is a fallback method in case we lose ability to publish to npmjs.com.
Find the latest release version
and copy the link to the node-client.tgz asset.
npm install --save [link to asset]
Pros:
Cons:
Applications would usually subclass the client:
export class Client extends NonAssociationsApi {
constructor(systemToken: string) {
super(
/**
* Provide a system token with necessary roles, not a user token
* READ_NON_ASSOCIATIONS and optionally WRITE_NON_ASSOCIATIONS or DELETE_NON_ASSOCIATIONS
* This must already be authenticated for the acting username
*/
systemToken,
/**
* API configuration standard in DPS front-end apps
*/
config.apis.hmppsNonAssociationsApi,
/**
* Logger such as standard library’s `console` or `bunyan` instance
*/
logger,
)
}
}
…and use the client in a request handler:
async (req, res) => {
const { user } = res.locals
const authClient = new AuthenticationClient( /* … */ ) // from @ministryofjustice/hmpps-auth-clients
const systemToken = authClient.getToken(user.username)
const api = new Client(systemToken)
const nonAssociation = await api.getNonAssociation(nonAssociationId)
}
NB: It is left to the application to determine which actions a user is allowed to perfom!
General notes regarding permissions and roles:
PRISON role, can view all non-associationsNON_ASSOCIATIONS role can add, update and close non-associations for prisoners both in a prison in any of their caseloadsGLOBAL_SEARCH role can also add, update and close non-associations for prisoners in transfer and where one prisoner is not in a prison that’s not in their caseloadsINACTIVE_BOOKINGS role can also add, update and close non-associations for prisoners outside any establishment / releasedDo not change the version set in package.json, it should remain "0.0.0".
node-client-[version] replacing [version] with the next version,
e.g. "node-client-0.1.7"FAQs
HMPPS Non-associations API REST client
The npm package @ministryofjustice/hmpps-non-associations-api receives a total of 21 weekly downloads. As such, @ministryofjustice/hmpps-non-associations-api popularity was classified as not popular.
We found that @ministryofjustice/hmpps-non-associations-api demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 10 open source maintainers collaborating on the project.
Did you know?

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.

Research
Malicious Namastex.ai npm packages appear to replicate TeamPCP-style Canister Worm tradecraft, including exfiltration and self-propagation.

Product
Explore exportable charts for vulnerabilities, dependencies, and usage with Reports, Socket’s new extensible reporting framework.

Product
Socket for Jira lets teams turn alerts into Jira tickets with manual creation, automated ticketing rules, and two-way sync.