Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

github.com/fabasoad/nsfw-detection-action

Package Overview
Dependencies
Alerts
File Explorer
Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/fabasoad/nsfw-detection-action

  • v2.0.4+incompatible
  • Source
  • Go
  • Socket score

Version published
Created
Source

NSFW detection action

Stand With Ukraine GitHub release (latest SemVer including pre-releases) unit-tests functional-tests security linting Maintainability Test Coverage Known Vulnerabilities

This action checks each modified and added file with the extensions that is defined in action configuration and failed in case of threshold of NSFW check is greater or equals to the threshold defined in action configuration. NSFW detection runs by chosen provider.

Contents

Providers

Cloudmersive

Identifier is cloudmersive. Sign up to Cloudmersive official website. Then go to API Keys page, create a new one and copy it.

DeepAI

Identifier is deepai. Sign up to DeepAI official website. Then go to Profile page and copy api-key that is located on the top of the page.

PicPurify

Identifier is picpurify. Sign up to PicPurify official website. Then go to API Keys page and copy API key that is located on the top of the page.

SightEngine

Identifier is sightengine. Sign up to SightEngine official website. Then go to Get Started page and copy API user and API secret from the examples provided. This provider requires to provide 2 API identifiers, so please put them into api_key parameter separated by comma. For example, your api_user is 123456 and api_secret is abcdef, so api_key should be 123456,abcdef.

Inputs

NameRequiredDescriptionDefaultPossible values
github_tokenYesGitHub token<String>
providerYesProvider identifier<String>
api_keyYesAPI key that should be used for chosen provider<String>
thresholdYesAction will be failed in case NSFW detection value will be greater or equal to this parameter<Float>
typeNoType of committed files separated by commamodified,added,renamedmodified,added,renamed
extensionsNoList of file extensions separated by commajpeg,jpg,png,gif,webp,tiff,bmpjpeg,jpg,png,gif,webp,tiff,bmp

Example usage

Workflow configuration

name: Test

on: push

jobs:
  nsfw-detection:
    name: Build
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@main
      - uses: fabasoad/nsfw-detection-action@main
        with:
          provider: deepai
          threshold: 0.9
          type: modified,added,renamed
          extensions: jpg,jpeg
          github_token: ${{ secrets.GITHUB_TOKEN }}
          api_key: ${{ secrets.DEEPAI_API_KEY }}

Result

Result

FAQs

Package last updated on 30 Jun 2024

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc