Skip to content

Instantly share code, notes, and snippets.

View Snawoot's full-sized avatar

Snawoot

  • Odessa, Ukraine
View GitHub Profile
@Snawoot
Snawoot / password.txt
Last active February 3, 2020 20:45 — forked from gabonator/password.txt
HiSilicon IP camera root passwords
Login Password
root xmhdipc
root klv123
root xc3511
root 123456
root jvbzd
default OxhlwSG8
defaul tlJwpbo6
defaul S2fGqNFs
default tluafed
@Snawoot
Snawoot / formatFilename.py
Created February 1, 2019 08:01 — forked from seanh/formatFilename.py
Turn any string into a valid filename in Python.
def format_filename(s):
"""Take a string and return a valid filename constructed from the string.
Uses a whitelist approach: any characters not present in valid_chars are
removed. Also spaces are replaced with underscores.
Note: this method may produce invalid filenames such as ``, `.` or `..`
When I use this method I prepend a date string like '2009_01_15_19_46_32_'
and append a file extension like '.txt', so I avoid the potential of using
an invalid filename.
#!/usr/bin/env python
# coding=utf-8
"""
LICENSE http://www.apache.org/licenses/LICENSE-2.0
"""
import datetime
import sys
import time
import threading
import traceback
#!/bin/bash
#
# Copyright (c) 2014, Intel Corporation
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# * Redistributions of source code must retain the above copyright notice,
# this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright