CyberSource / CyberSource/cybersource-rest-client-php

Capture Context fails if masking enabled

Open
#94 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
PHP
Stars
41
Forks
77
Avg merge
26m
Merged PRs (30d)
1

Description

\CyberSource\Api\KeyGenerationApi::generatePublicKey() will fail if masking is enabled.

The code fails in cybersource/rest-client-php/lib/Api/KeyGenerationApi.php, line 172 because $httpBody is an array and \CyberSource\Utilities\Helpers\DataMasker::maskData expects to be passed a JSON string.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in cybersource/rest-client-php/lib/Api/KeyGenerationApi.php at line 172 and inspect how generatePublicKey() passes $httpBody to DataMasker::maskData. Compare that call with DataMasker’s expected JSON-string input. Done means generatePublicKey() no longer fails when masking is enabled.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
api
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.