Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
== Welcome to Payment
Payment is used to process credit cards and electronic cash through merchant accounts.
To choose a gateway, require 'payment/gateway_name'. For example, if you want to use Authorize.net, do a require 'payment/authorize_net'. If you would like to use multiple gateways in the same code, simply do a require 'payment' and it will grab each gateway's code for you.
Payment was inspired by and has borrowed much of its infrastructure from the Business::OnlinePayment Perl module (http://search.cpan.org/~jasonk/Business-OnlinePayment-2.01/OnlinePayment.pm).
If you would like to loosely check the validity of a credit card without using a merchant account, look at the CreditCard module (http://rubyforge.org/projects/creditcard/).
== Example
require 'payment/authorize_net'
transaction = Payment::AuthorizeNet.new (
:login => 'username',
:password => 'password',
:amount => '49.95',
:card_number => '4012888818888',
:expiration => '03/10',
:first_name => 'John',
:last_name => 'Doe'
)
begin
transaction.submit
puts "Card processed successfully: #{transaction.authorization}"
rescue
puts "Card was rejected: #{transaction.error_message}"
end
To set default values, setup a file called .payment.yml in the home directory of the user who will be using this library. An example file would be:
username: my_account
transaction_key: my_trans_key
That way there is no need to keep sensitive information in your application's code itself. To specify an alternative configuration file, add a :prefs => '/path/to/file.yml' to the initialization parameters.
== Currently Supported Gateways
== Upcoming Gateways
== Planned Support for the Following Gateways
== About
Author:: Lucas Carlson (mailto:lucas@rufy.com) Copyright:: Copyright (c) 2005 Lucas Carlson License:: Distributes under the same terms as Ruby
FAQs
Unknown package
We found that payment 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
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.