anonymizer

package module
v0.0.0-...-2b689dc Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 21, 2023 License: MIT Imports: 1 Imported by: 0

README

go-pan-anonymizer

Anonymize PAN (Primary Account Number = Credit card number) in text.

Example

package main

import (
	"io"
	"os"

	anonymizer "github.com/kanmu/go-pan-anonymizer"
	"golang.org/x/text/transform"
)

func main() {
	io.Copy(os.Stdout, transform.NewReader(os.Stdin, anonymizer.DefaultAnonymizer()))
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultAnonymizer

func DefaultAnonymizer() *anonymizer

func NewAnonymizer

func NewAnonymizer(mask byte, test func([]byte) bool) *anonymizer

func TestLuhn

func TestLuhn(digits []byte) bool

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL