
Research
Supply Chain Attack on Axios Pulls Malicious Dependency from npm
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.
@artiomsu/angular-cc-library
Advanced tools
Angular CC Library - for validation and formating of input parameters
yarn installyarn run:demohttp://localhost:4200npm install angular-cc-library --save
On the input fields, add the specific directive to format inputs.
All fields must be type='tel' in order to support spacing and additional characters
import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { FormsModule } from '@angular/forms';
import { CreditCardDirectivesModule } from 'angular-cc-library';
import { AppComponent } from './app.component';
@NgModule({
imports: [BrowserModule, FormsModule, CreditCardDirectivesModule],
declarations: [AppComponent],
bootstrap: [AppComponent]
})
export class AppModule {
}
Credit Card Formatter
ccNumber directive:<input id="cc-number" type="tel" autocomplete="cc-number" ccNumber>
this will also apply a class name based off the card .visa, .amex, etc. See the array of card types in credit-card.ts for all available types
You can get parsed card type by using export api:
<input type="tel" ccNumber #ccNumber="ccNumber">
<span class="scheme">{{ccNumber.resolvedScheme$ | async}}</span>
resolvedScheme$ will be populated with visa, amex, etc.
Expiration Date Formatter Will support format of MM/YY or MM/YYYY
ccExp directive:<input id="cc-exp-date" type="tel" autocomplete="cc-exp" ccExp>
CVC Formater
ccCvc directive:<input id="cc-cvc" type="tel" autocomplete="off" ccCVC>
Current only Model Validation is supported. To implement, import the validator library and apply the specific validator on each form control
import { CreditCardValidators } from 'angular-cc-library';
@Component({
selector: 'app',
template: `
<form #demoForm="ngForm" (ngSubmit)="onSubmit(demoForm)" novalidate>
<input id="cc-number" formControlName="creditCard" type="tel" autocomplete="cc-number" ccNumber>
<input id="cc-exp-date" formControlName="expirationDate" type="tel" autocomplete="cc-exp" ccExp>
<input id="cc-cvc" formControlName="cvc" type="tel" autocomplete="off" ccCvc>
</form>
`
})
export class AppComponent implements OnInit {
form: FormGroup;
submitted: boolean = false;
constructor(private _fb: FormBuilder) {}
ngOnInit() {
this.form = this._fb.group({
creditCard: ['', [CreditCardValidators.validateCCNumber]],
expirationDate: ['', [CreditCardValidators.validateExpDate]],
cvc: ['', [Validators.required, Validators.minLength(3), Validators.maxLength(4)]]
});
}
onSubmit(form) {
this.submitted = true;
console.log(form);
}
}
Based on Stripe's jquery.payment plugin but adapted for use by Angular
MIT
FAQs
angular credit card library
We found that @artiomsu/angular-cc-library demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

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.

Research
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.

Security News
TeamPCP is partnering with ransomware group Vect to turn open source supply chain attacks on tools like Trivy and LiteLLM into large-scale ransomware operations.