Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
@covalent/http-deprec
Advanced tools
Abstract class provided with methods that wraps http services to facilitate REST API calls with @angular/http
.
Example:
import { Injectable } from '@angular/core';
import { Response, Http, Headers } from '@angular/http';
import { RESTService, HttpInterceptorService } from '@covalent/http-deprec';
@Injectable()
export class CustomRESTService extends RESTService<any> {
constructor(private _http: Http /* or HttpInterceptorService */) {
super(_http, {
baseUrl: 'www.api.com',
path: '/path/to/endpoint',
headers: new Headers(),
dynamicHeaders: () => new Headers(),
transform: (res: Response): any => res.json(),
});
}
}
Note: the constructor takes any object that implements the methods in [IHttp] interface. This can be the @angular [Http] service, the covalent [HttpInterceptorService] or a custom service.
export interface IHttp {
delete: (url: string, options?: RequestOptionsArgs) => Observable<Response>;
get: (url: string, options?: RequestOptionsArgs) => Observable<Response>;
head: (url: string, options?: RequestOptionsArgs) => Observable<Response>;
patch: (url: string, body: any, options?: RequestOptionsArgs) => Observable<Response>;
post: (url: string, body: any, options?: RequestOptionsArgs) => Observable<Response>;
put: (url: string, body: any, options?: RequestOptionsArgs) => Observable<Response>;
request: (url: string | Request, options: RequestOptionsArgs) => Observable<Response>;
}
FAQs
Teradata UI Platform Http Helper Module (deprecated)
We found that @covalent/http-deprec demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 open source maintainers 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
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.