open-index/open-npm huggingface dataset:
npm package: @sr9yar/digital-signature
Description: Digital Signature Cryptography
Author: Yaroslav
Latest version: 0.0.10

# Digital Signature

Digital Signature Systems implementation in JavaScript


<a href="https://ciphers.0x100.ru/assignment-3" title="Assignment">
Web interface 
</a>



```bash

npm i --save @sr9yar/digital-signature

```




## GOST 34.10-2012




## Publish

```bash


npm publish --access=public


```
npm package: @sr9yar/public-key-cryptography
Description: Public Key Cryptography
Author: Yaroslav
Latest version: 0.0.32

# Public Key Encryption

Public Key Encryption Systems implementation in JavaScript


<a href="https://ciphers.0x100.ru/assignment-2" title="Assignment">
Web interface 
</a>



```bash

npm i --save @sr9yar/public-key-cryptography

```




## RSA


## Rabin


## ElGamal
npm package: @sr9yar/simple-substitution-ciphers
Description: Simple Substitution Ciphers
Author: Yaroslav
Latest version: 0.1.15

# Simple Substitution Ciphers

Simple Substitution Ciphers implementation in JavaScript

<a href="https://ciphers.0x100.ru/assignment-1" title="Assignment">
Web interface 
</a>


```bash

npm i --save simple-substitution-ciphers

```




## Caesar Cipher



```js
// Создание экземпляра класса
import { Caesar } from './ciphers';
const cipher = new Caesar();

// Установка открытого текста / шифр текста
cipher.setPlaintext('криптография');
cipher.setCiphertext('знёмпланэсёь');

// Установка сдвига
cipher.shift = -3;

// Зашифрование, расшифрование и вывод результата в консоль (стандартный вывод)
const encrypted = cipher.encrypt();
console.log(`Encrypted: ${encrypted}\n`);

const decrypted = cipher.decrypt();
console.log(`Decrypted: ${decrypted}\n`);


```


## Affine Cipher



```js
// Создание экземпляра класса
import { Affine } from './ciphers';
const cipher = new Affine();

// Установка открытого текста / шифр текста
cipher.setPlaintext('криптография');
cipher.setCiphertext('шбкъоувбнькж');

// Установка ключа
cipher.a = 7;
cipher.b = 14;

// Зашифрование, расшифрование и вывод результата в консоль (стандартный вывод)
const encrypted = cipher.encrypt();
console.log(`Encrypted: ${encrypted}\n`);

const decrypted = cipher.decrypt();
console.log(`Decrypted: ${decrypted}\n`);


```



## Affine Recurrent Cipher



```js
// Создание экземпляра класса
import { AffineRecurrent } from './ciphers';
const cipher = new AffineRecurrent();

// Установка открытого текста / шифр текста
cipher.setPlaintext('криптография');
cipher.setCiphertext('шызъёсюезизс');

// Установка ключа
cipher.a1 = 7;
cipher.b1 = 14;
cipher.a2 = 5;
cipher.b2 = 9;

// Зашифрование, расшифрование и вывод результата в консоль (стандартный вывод)
const encrypted = cipher.encrypt();
console.log(`Encrypted: ${encrypted}\n`);

const decrypted = cipher.decrypt();
console.log(`Decrypted: ${decrypted}\n`);


```
npm package: @sr_logan/php-ver-manager
Description: A hark fork of ![jalendport/switch-php](https://github.com/jalendport/switch-php/blob/master/LICENSE.md) which aims to continue supporting new PHP versions and fixing any stability issues. Easily maintain and switch between PHP versions on your Mac. Requi
Author: Logan Schmidt
Latest version: 2.0.0

# php-ver-manager

A hark fork of ![jalendport/switch-php](https://github.com/jalendport/switch-php/blob/master/LICENSE.md) which aims to continue supporting new PHP versions and fixing any stability issues. 

Easily maintain and switch between PHP versions on your Mac. Requires ![Homebrew](https://brew.sh/) and works with Laravel Valet.

## Installation:

Installing `php-ver-manager` is as easy as running:

```
npm install --global php-ver-manager
```

If you use Yarn, you can do this:

```
yarn global add php-ver-manager
```

Alternatively you can move the `php-ver-manager.sh` file from this repo into your home directory and add this line in your `.bashrc`/`.zshrc`/etc.:

```
source ~/php-ver-manager.sh
```


### Usage:

You must have PHP installed via Homebrew in order for `php-ver-manager` to work. `php-ver-manager` also works really well with Laravel Valet, but Valet is not a requirement in order to use `php-ver-manager`.

Here's an example of how you would use `php-ver-manager`:

```
$ php-ver-manager 7.1 -v -m 512M
```

1. `php-ver-manager` -> The main command. (Required)
1. `7.1` -> Specify the version of PHP you want to switch too, in this case `php71`. (Required)
1. `-v` -> Request verbose output (Optional)
1. `-m 512M` -> Request a custom PHP memory setting. If you don't pass an additional arugment, the memory will be reset to the Valet default. (Optional)

Here's the full list of versions/options:

```bash
Usage:
  version [options] [arguments]

Options:
  -h, --help      Display the help message
  -v, --verbose   Display more info during the process
  -m, --memory    Customize the PHP memory setting (Valet only)

Available Versions:
  5.6              Switch to php@5.6
  7.0              Switch to php@7.0
  7.1              Switch to php@7.1
  7.2              Switch to php@7.2
  7.3              Switch to php@7.3
  7.4              Switch to php@7.4
  8.0              Switch to php@8.0
```


### Customizing the PHP Memory Settings:

- If you don't pass an argument to `-m` or `--memory`, it will reset any previously set custom memory settings to the default Valet config.
- Alternatively, you can pass an argument to `-m` or    `--memory` if you want to override the default Valet memory settings. For example, you can do:

```
php-ver-manager 7.1 -m 512M       # php@7.1 with 512MB of memory
php-ver-manager 7.3 -m 2G -v      # php@7.3 with 2GB of memory; verbose output
php-ver-manager 5.6 --memory=1G   # php@5.6 with 1GB of memory
```

- *Note: customizing PHP memory settings currently only works for Laravel Valet users. If you don't use Valet, we hope to get this working for you as well in an upcoming release.*
npm package: @sradevski/medusa-payment-halkbank
Description: Halkbank payment plugin for MedusaJS
Author: Stevche Radevski
Latest version: 1.0.0

# Halkbank Payment Plugin for MedusaJS

This plugin is a payment plugin for MedusaJS that allows you to accept payments from Halkbank MK. Halkbank uses Nestpay as a payment gateway, so the plugin can likely be adjusted to work with other banks that rely on Nestpay.

See [Halkbank Payment Plugin for MedusaJS - Frontend](https://www.npmjs.com/package/@sradevski/medusa-payment-halkbank-react) for the frontend component.

## Installation

> The plugin expects that the payment and cart module are available in the project.

**Install the plugin:**

- `npm i @sradevski/medusa-payment-halkbank`
- `yarn add @sradevski/medusa-payment-halkbank`
- `pnpm install @sradevski/medusa-payment-halkbank`

**Add the plugin to your Medusa project:**

```
  plugins: [
    {
      resolve: "@sradevski/medusa-payment-halkbank",
      options: {}
    },
  ]
```

**Add the Halkbank provider to payment module:**

```ts
  {
      resolve: "@medusajs/medusa/payment",
      options: {
        providers: [
          {
            resolve: "@sradevski/medusa-payment-halkbank/providers/halkbank",
            id: "halkbank",
            name: "Halkbank",
            options: {
              clientId: process.env.HALKBANK_CLIENT_ID,
              clientKey: process.env.HALKBANK_CLIENT_KEY,
            },
          },
        ],
      },
    },
```

The backend is ready to accept calls from the frontend component.
npm package: @sradevski/medusa-payment-halkbank-react
Description: React component to support payments with Halkbank for MedusaJS
Author: Stevche Radevski
Latest version: 1.0.1

# Halkbank Payment Plugin for MedusaJS

This plugin is a payment plugin for MedusaJS that allows you to accept payments from Halkbank MK. Halkbank uses Nestpay as a payment gateway, so the plugin can likely be adjusted to work with other banks that rely on Nestpay.

See [Halkbank Payment Plugin for MedusaJS - Backend](https://www.npmjs.com/package/@sradevski/medusa-payment-halkbank) for the backend plugin.

## Installation

**Install the frontend component:**

- `npm i @sradevski/medusa-payment-halkbank-react`
- `yarn add @sradevski/medusa-payment-halkbank-react`
- `pnpm install @sradevski/medusa-payment-halkbank-react`

**Import the HalkbankPayment component from the package:**

```
import { HalkbankPayment } from "@sradevski/medusa-payment-halkbank-react"
```

**Render the HalkbankPayment component:**

```
<HalkbankPayment
    cart={cart}
    clientId={process.env.NEXT_PUBLIC_HALKBANK_CLIENT_ID!}
    callbackUrl={`${process.env.NEXT_PUBLIC_HALKBANK_CALLBACK_URL}/${cart.id}`}
    language="mk"
    providerId="pp_halkbank_halkbank"
    initiatePaymentSession={(data) => initiatePaymentSession(cart, data)}
    onPaymentResponse={(resp) => {
        if (resp.error) {
            setError(resp.error)
        } else {
            finalizeCompletedCart(cart)
        }
    }}
    spinner={<Spinner />}
/>
```

**Initiating a payment session using the SDK:**

```
export async function initiatePaymentSession(
  cart: HttpTypes.StoreCart,
  data: {
    provider_id: string
    data: Record<string, unknown>
  }
) {
  return sdk.store.payment
    .initiatePaymentSession(cart, data, {}, await getAuthHeaders())
    .then((resp) => {
      return resp
    })
    .catch(medusaError)
}
```

**The environment variables you need to set will look like this:**

```
NEXT_PUBLIC_HALKBANK_CLIENT_ID=1234567890 // Information you got from Halkbank
NEXT_PUBLIC_HALKBANK_CALLBACK_URL=https://your-domain.com/hooks/halkbank
```

> Don't initiate a payment session early when using halkbank - Only render the HalkbankPayment component once the customer has selected as a payment method. Every time some of the cart data changes, a new session needs to be created, and the old one canceled.
npm package: @sraleik/meta-storage
Description: ## Description
Author: Sraleik
Latest version: 1.1.5

# Meta-Storage

## Description

Simple overlay on bluzelle Connection

- Strigify data before save
- JSON.parse data on read
- add a set function that create or update key when needed

## Installation

```bash
npm install @sraleik/meta-storage
```

```bash
yarn add @sraleik/meta-storage
```

```bash
pnpm add @sraleik/meta-storage
```

## Usage 

```javascript
const { createMockBluzelle } = require('@sraleik/mock-bluzelle');  //Or any kind of bluzelle connection
const { createMetaStorage } = require("@sraleik/meta-storage");

const mockBluzelle = await createMockBluzelle();
const metaStorage = await createMetaStorage(mockBluzelle);

await metaStorage.set('lol', {winner: 'chickenDinner'})
res = await metaStorage.read('lol')
```
npm package: @sraleik/mock-bluzelle
Description: ## Description
Author: Sraleik
Latest version: 1.0.4

# Mock Bluzelle 

## Description

Simple mock of bluzelle 

create the bluzelle interface for a key value storage (like nodeStorage)

## Installation

```bash
npm install @sraleik/mock-bluzelle
```

```bash
yarn add @sraleik/mock-bluzelle
```

```bash
pnpm add @sraleik/mock-bluzelle
```

### Simple Usage 

This will create a bluzelle like bdd using node-storage to persist data

```javascript
const { createMockBluzelle } = require('@sraleik/mock-bluzelle');
const mockBluzelle = await createMockBluzelle() 

await mockBluzelle.create('foo', 'bar')
simpleData = await mockBluzelle.read('foo')

console.log('simpleData',simpleData)
```

### Advance Usage 

This will create a bluzelle like bdd using your browser localStorage to persist data 

```javascript
const { bluzellifier } = require('@sraleik/mock-bluzelle');
const bluzelleLikeBdd = bluzellifier(window.localStorage)
const mockBluzelle = bluzelleLikeBdd({public: 'fake', private: 'morefake'})

await mockBluzelle.create('foo', 'bar')
simpleData = await mockBluzelle.read('foo')

console.log('simpleData',simpleData)
```