eggcrypt 1.2.0__tar.gz → 1.2.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: eggcrypt
3
- Version: 1.2.0
3
+ Version: 1.2.4
4
4
  Summary: A pretty secure (yet inneficient) encryption program. Has key(), hash(), encrypt() and decrypt().
5
5
  Author: Egglord
6
6
  License: MIT
@@ -24,7 +24,7 @@ eggcrypt.decrypt("") # Returns a non-encrypted string.
24
24
 
25
25
  eggcrypt.key() # Returns a random key/seed.
26
26
 
27
- eggcrypt.hash("") # Uses a custom method to hash a string
27
+ eggcrypt.hash("") # Uses a custom method to hash a string.
28
28
 
29
29
  # !NB!
30
30
 
@@ -12,7 +12,7 @@ eggcrypt.decrypt("") # Returns a non-encrypted string.
12
12
 
13
13
  eggcrypt.key() # Returns a random key/seed.
14
14
 
15
- eggcrypt.hash("") # Uses a custom method to hash a string
15
+ eggcrypt.hash("") # Uses a custom method to hash a string.
16
16
 
17
17
  # !NB!
18
18
 
@@ -0,0 +1 @@
1
+ from .egg import encrypt, decrypt, key, hash
@@ -49,9 +49,9 @@ def key():
49
49
  def hash(inp):
50
50
  inp=str(inp)
51
51
  tot=0
52
- for i in inp:
53
- tot+=ord(i)
54
- key=key()
52
+ for i,c in enumerate(inp):
53
+ tot+=(i+1)*ord(c)
54
+ key=(len(inp)*tot)^(tot*256)
55
55
  out=""
56
56
  for i in str(key):
57
57
  out+=str(int(i)+((tot*int(i))%256))
@@ -70,4 +70,4 @@ def hash(inp):
70
70
  x=""
71
71
  while h:x=chars[h%36]+x;h//=36
72
72
  out=x.zfill(50)
73
- return out
73
+ return out
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: eggcrypt
3
- Version: 1.2.0
3
+ Version: 1.2.4
4
4
  Summary: A pretty secure (yet inneficient) encryption program. Has key(), hash(), encrypt() and decrypt().
5
5
  Author: Egglord
6
6
  License: MIT
@@ -24,7 +24,7 @@ eggcrypt.decrypt("") # Returns a non-encrypted string.
24
24
 
25
25
  eggcrypt.key() # Returns a random key/seed.
26
26
 
27
- eggcrypt.hash("") # Uses a custom method to hash a string
27
+ eggcrypt.hash("") # Uses a custom method to hash a string.
28
28
 
29
29
  # !NB!
30
30
 
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "eggcrypt"
7
- version = "1.2.0"
7
+ version = "1.2.4"
8
8
  description = "A pretty secure (yet inneficient) encryption program. Has key(), hash(), encrypt() and decrypt()."
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.8"
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
2
2
 
3
3
  setup(
4
4
  name="egg",
5
- version="1.2.0",
5
+ version="1.2.4",
6
6
  packages=find_packages(),
7
7
  description="A pretty secure (yet inneficient) encryption program.",
8
8
  author="Egglord",
@@ -1 +0,0 @@
1
- from .egg import encrypt, decrypt, key
File without changes
File without changes