Completed
Push — master ( e7778f...95d0df )
by
unknown
33s
created

ShaIt   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 5
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 5
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A run() 0 4 1
1
from __future__ import print_function
2
3
from Crypto.Hash import SHA
4
5
from st2actions.runners.pythonrunner import Action
6
7
__all__ = [
8
    'ShaIt'
9
]
10
11
12
class ShaIt(Action):
13
    def run(self, message, handle):
14
        sha_message = message + handle
15
16
        return SHA.new(sha_message).hexdigest()
17