security

package
v1.0.17 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2026 License: Apache-2.0, BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Overview

*

  • Copyright 2022 Comcast Cable Communications Management, LLC *
  • Licensed under the Apache License, Version 2.0 (the "License");
  • you may not use this file except in compliance with the License.
  • You may obtain a copy of the License at *
  • http://www.apache.org/licenses/LICENSE-2.0 *
  • Unless required by applicable law or agreed to in writing, software
  • distributed under the License is distributed on an "AS IS" BASIS,
  • WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  • See the License for the specific language governing permissions and
  • limitations under the License. *
  • SPDX-License-Identifier: Apache-2.0

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decrypt

func Decrypt(xpckeyB64 string, encryptedB64 string) string

func Digest

func Digest(iv []byte, plaintextstr string) []byte

func Padding

func Padding(ciphertext []byte, blockSize int) []byte

Types

type AesCodec

type AesCodec struct {
	// contains filtered or unexported fields
}

func NewAesCodec

func NewAesCodec(keyB64 string) *AesCodec

func (*AesCodec) Decrypt

func (c *AesCodec) Decrypt(encryptedB64 string) (string, error)

func (*AesCodec) DecryptWithoutPadding

func (c *AesCodec) DecryptWithoutPadding(encryptedB64 string) (string, error)

func (*AesCodec) Encrypt

func (c *AesCodec) Encrypt(plaintextstr string) (string, error)

func (*AesCodec) EncryptWithoutPadding

func (c *AesCodec) EncryptWithoutPadding(plaintextstr string) (string, error)

Jump to

Keyboard shortcuts

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