首页 > 系统相关 >Linux shell command base64 All In One

Linux shell command base64 All In One

时间:2023-05-30 22:22:04浏览次数:52  
标签:shell help -- base64 decode coreutils command xgqfrms

Linux shell command base64 All In One

email address encryption / 邮箱地址加密

应用场景

防止爬虫爬取邮箱地址发送垃圾邮件

base64 encode & decode

$ base64 --version
base64 (GNU coreutils) 8.32
Copyright (C) 2020 Free Software Foundation, Inc.
许可证 GPLv3+:GNU 通用公共许可证第 3 版或更新版本<https://gnu.org/licenses/gpl.html>。
本软件是自由软件:您可以自由修改和重新发布它。
在法律范围内没有其他保证。
由Simon Josefsson 编写。
$ base64 --help
用法:base64 [选项]... [文件]
使用 Base64 编码/解码文件或标准输入输出。

如果没有指定文件,或者文件为"-",则从标准输入读取。

必选参数对长短选项同时适用。
  -d, --decode		解码数据
  -i, --ignore-garbag	解码时忽略非字母字符
  -w, --wrap=字符数	在指定的字符数后自动换行(默认为76),0 为禁用自动换行

      --help		显示此帮助信息并退出
      --version		显示版本信息并退出

数据以 RFC 4648 规定的 base64 字母格式进行编码。
解码时,输入数据(编码流)可能包含一些非有效 base64 字符以及换行符。
可以尝试用 --ignore-garbage 选项来绕过编码流中的无效字符。

GNU coreutils 在线帮助:<https://www.gnu.org/software/coreutils/>
请向 <http://translationproject.org/team/zh_CN.html> 报告任何翻译错误
完整文档 <https://www.gnu.org/software/coreutils/base64>
或者在本地使用:info '(coreutils) base64 invocation'

https://www.gnu.org/software/coreutils/base64

https://www.gnu.org/software/coreutils/

http://translationproject.org/team/zh_CN.html

$ man base64

BASE64(1)                                          User Commands                                          BASE64(1)

NAME
       base64 - base64 encode/decode data and print to standard output

SYNOPSIS
       base64 [OPTION]... [FILE]

DESCRIPTION
       Base64 encode or decode FILE, or standard input, to standard output.

       With no FILE, or when FILE is -, read standard input.

       Mandatory arguments to long options are mandatory for short options too.

       -d, --decode
              decode data

       -i, --ignore-garbage
              when decoding, ignore non-alphabet characters

       -w, --wrap=COLS
              wrap encoded lines after COLS character (default 76).  Use 0 to disable line wrapping

       --help display this help and exit

       --version
              output version information and exit

       The data are encoded as described for the base64 alphabet in RFC 4648.  When decoding, the input may contain
       newlines in addition to the bytes of the formal base64 alphabet.  Use --ignore-garbage to attempt to recover
       from any other non-alphabet bytes in the encoded stream.

AUTHOR
       Written by Simon Josefsson.

REPORTING BUGS
       GNU coreutils online help: <https://www.gnu.org/software/coreutils/>
       Report any translation bugs to <https://translationproject.org/team/>

COPYRIGHT
       Copyright   ©   2020   Free  Software  Foundation,  Inc.   License  GPLv3+:  GNU  GPL  version  3  or  later
       <https://gnu.org/licenses/gpl.html>.
       This is free software: you are free to change and redistribute it.  There is NO WARRANTY, to the extent per‐
       mitted by law.

SEE ALSO
       Full documentation <https://www.gnu.org/software/coreutils/base64>
       or available locally via: info '(coreutils) base64 invocation'

GNU coreutils 8.32                                 September 2020                                         BASE64(1)
 Manual page base64(1) line 1/51 (END) (press h for help or q to quit)


demos

# encode / 加密
$ echo "[email protected]" | base64
eGdxZnJtc0B4Z3Fmcm1zLnh5ego=

# decode / 解密
$ echo "eGdxZnJtc0B4Z3Fmcm1zLnh5ego=" | base64 --decode

# alias
$ echo "eGdxZnJtc0B4Z3Fmcm1zLnh5ego=" | base64 -d

image

(

标签:shell,help,--,base64,decode,coreutils,command,xgqfrms
From: https://www.cnblogs.com/xgqfrms/p/17444674.html

相关文章

  • shellcode的一个demo例子
    handy-shellcodeBinaryExploitation,50pointsDescription:Thisprogramexecutesanyshellcodethatyougiveit.Canyouspawnashellandusethattoreadtheflag.txt?#include<stdio.h>#include<stdlib.h>#include<string.h>#include&l......
  • 小括号() 大括号{}在linux shell中的作用
    1.小括号()a.另开子shell运行命令比如(ls;ls-h;pwd);b.参数替换,类似于``;2.大括号{} a.参数收拢比如ls{a,b,c}.txt{1...3}.txtb.在当前shell中执行命令{ls;pwd;},需要注意左大括号与第一条命令有空格,最后一条命令后带分号。3.小括号嵌套两层(())  ......
  • How to use the shell command to get the version of Linux Distributions All In On
    HowtousetheshellcommandtogettheversionofLinuxDistributionsAllInOne如何使用shell命令获取Linux发行版的版本hostnamectlcat/etc/os-releaselsb_release-aLinuxDistributionsDebianUbuntuRaspberryPiOShttps://en.wikipedia.org/wiki/L......
  • go exec.Command windows 参数引号转义问题
    Go在windows上调用本地进程传参时的一个天坑Golanggo在windows上exec.Command调用本地进程在传参的时候有一个天坑,举个栗子来说正常来说一般代码会这么写cmdLine:="notepad.exe"+`"D:\ProgramFiles\Notepad++\session.xml"`cmd:=exec.Command("cmd.exe","/c",cmdL......
  • Python 读取图片 转 base64 并生成 JSON
    Python读取图片转base64并生成JSONimportjsonimportbase64img_path=r'D:\OpenSource\PaddlePaddle\PaddleOCR\images\005.jpeg';withopen(img_path,'rb')asfile:image_data1=file.read()image=base64.b64encode(image_data1).de......
  • Linux(Ubuntu)下设置开机自启shell脚本执行Java程序jar包
    Linux(Ubuntu)下设置开机自启shell脚本执行Java程序jar包 原创软件测试日常记录2023-01-1907:19:29博主文章分类:ubuntu©著作权文章标签ubuntujarlinuxJAVAjava文章分类运维阅读数122 经常需要在Linux服务器上设置开机启动jar包,首先编写一个启动jar包的脚本,这里以/......
  • 非常不错的springboot启动shell脚本
    #!/bin/bashJAVA_OPTIONS_INITIAL=-Xms256MJAVA_OPTIONS_MAX=-Xmx256M_JAR_KEYWORDS=/wls/appsystem/ruoyi/apps/ruoyi-admin.jarAPP_NAME=ruoyi-adminAPPLICATION_FILE=/wls/appsystem/ruoyi/config/application.propertiesAPPLICATION_YAML_FILE=/wls/appsystem/ruoyi......
  • Linux 06 Shell
    Shell脚本脚本声明#!/bin/bash脚本注释#examplescript脚本命令uptimefree-hreboot脚本执行$catxiaoxian.sh#!/bin/bash#xiaoxian.sh#thisscriptistest#2023-05-09datels-lfree-huname-a$bashxiaoxian.sh接收用户输入$catha......
  • Shell - shell中的运算符
    基本语法使用案例   基本语法$((运算式))$[运算式]  使用案例#第一种写法a=10b=20c=`expr${a}+${b}`echo"$c"#第二种写法c=$[`expr10+20`]echo"$c"#第三种写法c=$[10+20]echo"$c"#计算3加2的值expr3+2#计算3减2的值e......
  • 检测CPU,内存,磁盘使用率shell
    检测CPU,内存,磁盘使用率shell 1.检测CPU,内存,磁盘使用率超过80%,则发送邮件告警#!/bin/bash#当前主机ipHOST=$(ipashoweth0|grep'\inet\b'|awk'{print$2}'|sed's/\/.*//')#告警邮箱[email protected]#磁盘使用百分比阈值DISK_USAGE_THRESHOLD=80#CPU......