Giter Club home page Giter Club logo

doc-signer's Introduction

Doc Signer, OTP Verification and Signature Printing Application

This application provides a way for a user to send a predefined PDF to a predefined printer, using OTP (One-Time Password) generation and verification. One use of this application is to send a predefined signature to a printer, allowing the user to effectively "sign checks" by printing the signature over the top of printed checks.

It is built using Flask and includes logging for important events.

Prerequisites

  • Python 3.11+
  • pip (Python package installer)
  • Virtual environment (optional but recommended)
  • PDF to Printer (or any other PDF to Printer software)

Installation

  1. Clone the repository:

    git clone https://github.com/jcarter62/doc-signer.git
    cd <repository-directory>
  2. Create and activate a virtual environment (optional but recommended):

    python -m venv venv
    source venv/bin/activate  # On Windows use `venv\Scripts\activate`
  3. Install the required packages:

    pip install -r requirements.txt
  4. Set up environment variables:

    Create a .env file in the root directory of the project and add the following variables:

    PRINTER_EXE=c:\...\PDFtoPrinter.exe
    PRINTER1=hpprinter
    NAME=Jim User
    EMAIL=[email protected]
    PDFFILE=c:\temp\one-page.pdf
    OTP_FILE=c:\temp\otp.txt
    EMAIL_SERVER=192.168.1.100
    EMAIL_PORT=25
    EMAIL_FROM=[email protected]
    HOST=0.0.0.0
    PORT=5000

Configuration

  1. Static Files:

    Ensure that the image files are placed in the static directory. For example, pen-writing-on-check.png should be located at static/pen-writing-on-check.png.

  2. Templates:

    The HTML templates are located in the templates directory. You can customize home.html and success.html as needed.

Running the Application

  1. Start the application using run.py:

    python run.py

    This will start the server with logging configured in run.py.

Logging

Logging is configured in run.py to log important events and errors to the console. You can view the logs in the terminal where you start the application.

Usage

  1. Generate OTP:

    Navigate to the home page and click on "Generate New OTP Code". The OTP will be sent to your email.

  2. Verify OTP:

    Enter the OTP code received in your email and click "Verify OTP Code".

  3. Print Signature:

    After OTP verification, enter the quantity of signatures to print and click "Print".

External Resources

doc-signer's People

Contributors

jcarter62 avatar

Watchers

 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.