First commit

master
Daniel Berteaud 5 years ago
commit 6a31c5b358
  1. 96
      .gitignore
  2. 5
      LICENSE
  3. 1
      README.md
  4. 27
      WAPT/control
  5. BIN
      WAPT/icon.png
  6. 295
      WAPT/wapt.psproj
  7. 27
      setup.py

96
.gitignore vendored

@ -0,0 +1,96 @@
# ---> Python
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class
# C extensions
*.so
# Distribution / packaging
.Python
env/
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
*.egg-info/
.installed.cfg
*.egg
# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec
# Installer logs
pip-log.txt
pip-delete-this-directory.txt
# Unit test / coverage reports
htmlcov/
.tox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*,cover
.hypothesis/
# Translations
*.mo
*.pot
# Django stuff:
*.log
local_settings.py
# Flask stuff:
instance/
.webassets-cache
# Scrapy stuff:
.scrapy
# Sphinx documentation
docs/_build/
# PyBuilder
target/
# Jupyter Notebook
.ipynb_checkpoints
# pyenv
.python-version
# celery beat schedule file
celerybeat-schedule
# SageMath parsed files
*.sage.py
# dotenv
.env
# virtualenv
.venv
venv/
ENV/
# Spyder project settings
.spyderproject
# Rope project settings
.ropeproject

@ -0,0 +1,5 @@
MIT License
Copyright (c) <year> <copyright holders>
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

@ -0,0 +1 @@
Dummy package to debug encrypted variables issues

@ -0,0 +1,27 @@
package : fws-variables-debug
version : 1
architecture : all
section : base
priority : high
maintainer : Daniel Berteaud <daniel@firewall-services.com>
description : Encrypted vars debuging package
depends :
conflicts :
maturity : PROD
locale :
target_os : windows
min_os_version : 5.0
max_os_version :
min_wapt_version : 1.5
sources :
installed_size :
impacted_process :
editor : Firewall Services
keywords :
licence : MIT
homepage : https://www.firewall-services.com
package_uuid :
signer : Daniel Berteaud
signer_fingerprint:
signature_date :
signed_attributes :

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.5 KiB

@ -0,0 +1,295 @@
[PyScripter]
Version=3.3.2.0
[Project]
ClassName=TProjectRootNode
StoreRelativePaths=TRUE
ShowFileExtensions=FALSE
[Project\ChildNodes\Node0]
ClassName=TProjectFilesNode
[Project\ChildNodes\Node0\ChildNodes\Node0]
ClassName=TProjectFolderNode
Name=wapt
[Project\ChildNodes\Node0\ChildNodes\Node0\ChildNodes\Node0]
ClassName=TProjectFileNode
FileName=C:\Program Files (x86)\wapt\common.py
[Project\ChildNodes\Node0\ChildNodes\Node0\ChildNodes\Node1]
ClassName=TProjectFileNode
FileName=C:\Program Files (x86)\wapt\setuphelpers.py
[Project\ChildNodes\Node0\ChildNodes\Node0\ChildNodes\Node2]
ClassName=TProjectFileNode
FileName=C:\Program Files (x86)\wapt\wapt-get.ini
[Project\ChildNodes\Node0\ChildNodes\Node0\ChildNodes\Node3]
ClassName=TProjectFileNode
FileName=C:\Program Files (x86)\wapt\wapt-get.py
[Project\ChildNodes\Node0\ChildNodes\Node0\ChildNodes\Node4]
ClassName=TProjectFileNode
FileName=C:\Program Files (x86)\wapt\waptpackage.py
[Project\ChildNodes\Node0\ChildNodes\Node0\ChildNodes]
Count=5
[Project\ChildNodes\Node0\ChildNodes\Node1]
ClassName=TProjectFileNode
FileName=$[Project-Path]changelog.txt
[Project\ChildNodes\Node0\ChildNodes\Node2]
ClassName=TProjectFileNode
FileName=$[Project-Path]control
[Project\ChildNodes\Node0\ChildNodes\Node3]
ClassName=TProjectFileNode
FileName=$[Project-Path]..\setup.py
[Project\ChildNodes\Node0\ChildNodes]
Count=4
[Project\ChildNodes\Node1]
ClassName=TProjectRunConfiguationsNode
[Project\ChildNodes\Node1\ChildNodes\Node0]
ClassName=TProjectRunConfiguationNode
Name=install
[Project\ChildNodes\Node1\ChildNodes\Node0\RunConfig]
ScriptName=C:\Program Files (x86)\wapt\wapt-get.py
EngineType=peRemote
ReinitializeBeforeRun=TRUE
Parameters=install "$[Project-Path].."
WorkingDir=$[Project-Path]..
WriteOutputToFile=FALSE
OutputFileName=$[ActiveScript-NoExt].log
AppendToFile=FALSE
[Project\ChildNodes\Node1\ChildNodes\Node0\RunConfig\ExternalRun]
Caption=External Run
Description=Run script using an external Python Interpreter
ApplicationName=$[PythonExe-Short]
Parameters=$[ActiveScript-Short]
WorkingDirectory=$[ActiveScript-Dir]
ShortCut=0
MessagesFormat=$[FileName] $[LineNumber]
[Project\ChildNodes\Node1\ChildNodes\Node1]
ClassName=TProjectRunConfiguationNode
Name=remove
[Project\ChildNodes\Node1\ChildNodes\Node1\RunConfig]
ScriptName=C:\Program Files (x86)\wapt\wapt-get.py
EngineType=peRemote
ReinitializeBeforeRun=TRUE
Parameters=remove "$[Project-Path].."
WorkingDir=$[Project-Path]..
WriteOutputToFile=FALSE
OutputFileName=$[ActiveScript-NoExt].log
AppendToFile=FALSE
[Project\ChildNodes\Node1\ChildNodes\Node1\RunConfig\ExternalRun]
Caption=External Run
Description=Run script using an external Python Interpreter
ApplicationName=$[PythonExe-Short]
Parameters=$[ActiveScript-Short]
WorkingDirectory=$[ActiveScript-Dir]
ShortCut=0
MessagesFormat=$[FileName] $[LineNumber]
[Project\ChildNodes\Node1\ChildNodes\Node2]
ClassName=TProjectRunConfiguationNode
Name=session-setup
[Project\ChildNodes\Node1\ChildNodes\Node2\RunConfig]
ScriptName=C:\Program Files (x86)\wapt\wapt-get.py
EngineType=peRemote
ReinitializeBeforeRun=TRUE
Parameters=session-setup "$[Project-Path].."
WorkingDir=$[Project-Path]..
WriteOutputToFile=FALSE
OutputFileName=$[ActiveScript-NoExt].log
AppendToFile=FALSE
[Project\ChildNodes\Node1\ChildNodes\Node2\RunConfig\ExternalRun]
Caption=External Run
Description=Run script using an external Python Interpreter
ApplicationName=$[PythonExe-Short]
Parameters=$[ActiveScript-Short]
WorkingDirectory=$[ActiveScript-Dir]
ShortCut=0
MessagesFormat=$[FileName] $[LineNumber]
[Project\ChildNodes\Node1\ChildNodes\Node3]
ClassName=TProjectRunConfiguationNode
Name=update
[Project\ChildNodes\Node1\ChildNodes\Node3\RunConfig]
ScriptName=C:\Program Files (x86)\wapt\wapt-get.py
EngineType=peRemote
ReinitializeBeforeRun=TRUE
Parameters=update
WorkingDir=$[Project-Path]..
WriteOutputToFile=FALSE
OutputFileName=$[ActiveScript-NoExt].log
AppendToFile=FALSE
[Project\ChildNodes\Node1\ChildNodes\Node3\RunConfig\ExternalRun]
Caption=External Run
Description=Run script using an external Python Interpreter
ApplicationName=$[PythonExe-Short]
Parameters=$[ActiveScript-Short]
WorkingDirectory=$[ActiveScript-Dir]
ShortCut=0
MessagesFormat=$[FileName] $[LineNumber]
[Project\ChildNodes\Node1\ChildNodes\Node4]
ClassName=TProjectRunConfiguationNode
Name=upgrade
[Project\ChildNodes\Node1\ChildNodes\Node4\RunConfig]
ScriptName=C:\Program Files (x86)\wapt\wapt-get.py
EngineType=peRemote
ReinitializeBeforeRun=TRUE
Parameters=-f upgrade
WorkingDir=$[ActiveScript-Dir]
WriteOutputToFile=FALSE
OutputFileName=$[ActiveScript-NoExt].log
AppendToFile=FALSE
[Project\ChildNodes\Node1\ChildNodes\Node4\RunConfig\ExternalRun]
Caption=External Run
Description=Run script using an external Python Interpreter
ApplicationName=$[PythonExe-Short]
Parameters=$[ActiveScript-Short]
WorkingDirectory=$[ActiveScript-Dir]
ShortCut=0
MessagesFormat=$[FileName] $[LineNumber]
[Project\ChildNodes\Node1\ChildNodes\Node5]
ClassName=TProjectRunConfiguationNode
Name=-i build-upload
[Project\ChildNodes\Node1\ChildNodes\Node5\RunConfig]
ScriptName=C:\Program Files (x86)\wapt\wapt-get.py
EngineType=peRemote
ReinitializeBeforeRun=TRUE
Parameters=-i build-upload "$[Project-Path].."
WorkingDir=$[Project-Path]..
WriteOutputToFile=FALSE
OutputFileName=$[ActiveScript-NoExt].log
AppendToFile=FALSE
[Project\ChildNodes\Node1\ChildNodes\Node5\RunConfig\ExternalRun]
Caption=External Run
Description=Run script using an external Python Interpreter
ApplicationName=$[PythonExe-Short]
Parameters=$[ActiveScript-Short]
WorkingDirectory=$[ActiveScript-Dir]
ShortCut=0
MessagesFormat=$[FileName] $[LineNumber]
[Project\ChildNodes\Node1\ChildNodes\Node6]
ClassName=TProjectRunConfiguationNode
Name=svn update
[Project\ChildNodes\Node1\ChildNodes\Node6\RunConfig]
ScriptName=C:\Program Files (x86)\wapt\wapt-get.py
EngineType=peRemote
ReinitializeBeforeRun=TRUE
Parameters=sources "$[Project-Path].."
WorkingDir=$[Project-Path]..
WriteOutputToFile=FALSE
OutputFileName=$[ActiveScript-NoExt].log
AppendToFile=FALSE
[Project\ChildNodes\Node1\ChildNodes\Node6\RunConfig\ExternalRun]
Caption=External Run
Description=Run script using an external Python Interpreter
ApplicationName=$[PythonExe-Short]
Parameters=$[ActiveScript-Short]
WorkingDirectory=$[ActiveScript-Dir]
ShortCut=0
MessagesFormat=$[FileName] $[LineNumber]
[Project\ChildNodes\Node1\ChildNodes\Node7]
ClassName=TProjectRunConfiguationNode
Name=uninstall
[Project\ChildNodes\Node1\ChildNodes\Node7\RunConfig]
ScriptName=C:\Program Files (x86)\wapt\wapt-get.py
EngineType=peRemote
ReinitializeBeforeRun=TRUE
Parameters=uninstall "$[Project-Path].."
WorkingDir=$[Project-Path]..
WriteOutputToFile=FALSE
OutputFileName=$[ActiveScript-NoExt].log
AppendToFile=FALSE
[Project\ChildNodes\Node1\ChildNodes\Node7\RunConfig\ExternalRun]
Caption=External Run
Description=Run script using an external Python Interpreter
ApplicationName=$[PythonExe-Short]
Parameters=$[ActiveScript-Short]
WorkingDirectory=$[Project-Path]..
ShortCut=0
MessagesFormat=$[FileName] $[LineNumber]
[Project\ChildNodes\Node1\ChildNodes\Node8]
ClassName=TProjectRunConfiguationNode
Name=update-package-sources
[Project\ChildNodes\Node1\ChildNodes\Node8\RunConfig]
ScriptName=C:\Program Files (x86)\wapt\wapt-get.py
EngineType=peRemote
ReinitializeBeforeRun=TRUE
Parameters=update-package-sources "$[Project-Path].."
WorkingDir=$[Project-Path]..
WriteOutputToFile=FALSE
OutputFileName=$[ActiveScript-NoExt].log
AppendToFile=FALSE
[Project\ChildNodes\Node1\ChildNodes\Node8\RunConfig\ExternalRun]
Caption=External Run
Description=Run script using an external Python Interpreter
ApplicationName=$[PythonExe-Short]
Parameters=$[ActiveScript-Short]
WorkingDirectory=$[ActiveScript-Dir]
ShortCut=0
MessagesFormat=$[FileName] $[LineNumber]
[Project\ChildNodes\Node1\ChildNodes\Node9]
ClassName=TProjectRunConfiguationNode
Name=audit
[Project\ChildNodes\Node1\ChildNodes\Node9\RunConfig]
ScriptName=C:\Program Files (x86)\wapt\wapt-get.py
EngineType=peRemote
ReinitializeBeforeRun=TRUE
Parameters=audit "$[Project-Path].."
WorkingDir=$[Project-Path]..
WriteOutputToFile=FALSE
OutputFileName=$[ActiveScript-NoExt].log
AppendToFile=FALSE
[Project\ChildNodes\Node1\ChildNodes\Node9\RunConfig\ExternalRun]
Caption=External Run
Description=Run script using an external Python Interpreter
ApplicationName=$[PythonExe-Short]
Parameters=$[ActiveScript-Short]
WorkingDirectory=$[ActiveScript-Dir]
ShortCut=0
MessagesFormat=$[FileName] $[LineNumber]
[Project\ChildNodes\Node1\ChildNodes]
Count=10
[Project\ChildNodes]
Count=2
[Project\ExtraPythonPath]
Count=0

@ -0,0 +1,27 @@
# -*- coding: UTF-8 -*-
from setuphelpers import *
uninstallkey = []
variables = {}
# Read local variables file if available
if isfile(makepath(programfiles32,'wapt','private','symetric.txt')) and isfile(makepath(programfiles32,'wapt','private','variables.txt')):
print('Reading local encrypted variables file')
from cryptography.fernet import Fernet
import yaml
key = open(makepath(programfiles32,'wapt','private','symetric.txt'),'r').read()
print('Key is %s', % key)
f = Fernet(key)
print('Fernet object created')
crypted_var = open(makepath(programfiles32,'wapt','private','variables.txt'),'r').read()
print('Encrypted vars found : %s' % crypted_var)
decrypted_var = f.decrypt(crypted_var)
print('Decrypted vars %s' % decrypted_var
def install():
print('Nothing to do')
def uninstall():
print('Nothing to do')
Loading…
Cancel
Save