Code Monkey home page Code Monkey logo

ts.cryptojs256's Introduction

CryptoJS - 256 Titanium Alloy License

This module for the Appcelerator Titanium Alloy MVC framework brings CryptoJS 256 methods into Titanium.

Quick Start

Get it gitTio

Download this repository and install it

  • In your application's tiapp.xml file, add the module to the modules section:
<modules>
    <module platform="commonjs">ts.cryptojs256</module>
</modules>
  • Copy the ts.cryptojs256-commonjs-x.x.x.zip bundle into your root app directory.

Or use your favorite package manager

  • gitTio: gittio install ts.cryptojs256

Use it

var CryptoJS = require('ts.cryptojs256');

var encodedString = CryptoJS.enc.base64.stringify("The Smiths");
var hmacHash = CryptoJS.HmacSHA256("The Smiths", "Secret Key");

// Please refer to the original documentation of CryptoJS for more information and examples.

API

CryptoJS.enc.Base64

A Base64 encoder object

CryptoJS.enc.Base64.stringify(str) :: {String}

Encode a string using Base64 encoder

  • {String} str The given string to encode
  • return {String} The encoded string
CryptoJS.enc.Base64.parse(str) :: {String}

Decode an Base64 encoded string

  • {String} str The given string to decode
  • return {String} The decoded string
CryptoJS.enc.Utf8

A Utf8 encoder object

CryptoJS.enc.Utf8.stringify(str) :: {String}

Encode a string using Utf8 encoder

  • {String} str The given string to encode
  • return {String} The encoded string
CryptoJS.enc.Utf8.parse(str) :: {String}

Decode an Utf8 encoded string

  • {String} str The given string to decode
  • return {String} The decoded string
CryptoJS.enc.Latin1

A Latin1 encoder object

CryptoJS.enc.Latin1.stringify(str) :: {String}

Encode a string using Latin1 encoder

  • {String} str The given string to encode
  • return {String} The encoded string
CryptoJS.enc.Latin1.parse(str) :: {String}

Decode an Latin1 encoded string

  • {String} str The given string to decode
  • return {String} The decoded string
CryptoJS.SHA256(str) :: {String}

Crypt a string using a SHA256 algorithm

  • {String} str The given string to crypt
  • return {String} The crypted string
CryptoJS.HmacSHA256(str, secretKey) :: {String}

Crypt a string using a Hmac256 algorithm and a secret key

  • {String} str The given string to crypt
  • {String} secretKey The secret key used for encryption
  • return {String} The crypted string

Changelog

  • 1.0 First version

wearesmiths

Appcelerator, Appcelerator Titanium and associated marks and logos are trademarks of Appcelerator, Inc.
Titanium is Copyright (c) 2008-2015 by Appcelerator, Inc. All Rights Reserved.
Titanium is licensed under the Apache Public License (Version 2).

ts.cryptojs256's People

Contributors

ktorz avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.