卡菲小姐利用PTT網軍網路霸凌?Ms. Kaffi 婚攝, 婚紗

卡菲小姐利用PTT網軍網路霸凌?Ms. Kaffi 婚攝, 婚紗

Ms. Kaffi 婚攝, 婚紗, 卡菲小姐
前情提要:https://www.dcard.tw/f/marriage/p/236591845

剛剛在結婚版看到這篇,覺得真是超級扯扯爆ㄌ,又看到另一篇說網軍操作,決定搬移始末跟證據來發文,不知道發哪裡好,所以來發閒聊

以下懶人包 總共九點
參考PTT HellNo大:

<七月二十八>
1. 新人發現一間完全不認識的攝影工作室「花朵影像製作」用自己的婚紗照發文,內心WTF,詢問該工作室才發現,是當初花$$請的「卡菲小姐影像」的攝影師「Megan Liang/梅根/小梁」在「未經告知」的情況下,隨意將照片「給第三方商用」
2. 當天快下午兩點,新人在PTT等平臺發反推文,並隨後詢問攝影師,有於私訊中強調自己「未授權」https://www.ptt.cc/bbs/GetMarry/M.1627451917.A.0DF.html
下午三點五十三分,攝影師回覆「大方承認,當作沒事」,表示有合作,也沒有第一時間道歉,新人只好再度強調未被詢問跟授權,此時攝影師才表示要下架照片,於是新人將訊息截圖更新發文,對於攝影師態度表示不滿。

=時隔多日=
<八月十六>
3. 原以為事情告一段落,十六日早上十一點二十七分攝影師在臉書發文,說新人在三個平台指責他都不道歉,接著公開與新人協調過程,指「新人刁難、抹黑」,明明已事隔多日,新人也無其他動作,攝影師卻自己發文批評「新人不想讓事情結束」,並將貼文設為置頂。
4. 當天中午攝影師友人代Po澄清文於PTT,開頭先道歉,並強調自己已有跟新人私下道歉,後續提出藉口,稱新人對於之前公開照片沒有意見、簽約是禮服工作室所簽,因所收金額視為公開,然新人第一篇文已有貼出合約,「合約完全無註明公開條約」,且整篇道歉文忽略「第三方商用」爭議。
https://www.ptt.cc/bbs/GetMarry/M.1629086519.A.CF4.html
5. 晚上,沉寂已久的新人反推文亦出現大量帳號推文護航攝影師,指責新人、牽拖合約,撇清攝影師的責任,表示「攝影師可憐」,同樣在代Po的攝影師澄清文下面也出現大量護航攝影師推文,支持攝影師,事情延燒。
<八月十七>
6. 由於攝影師臉書公開指責新人協調過程中難搞,半夜新人再度發文,開頭再度強調反推發文原因是「未經同意第三方商用」,接著解釋與攝影師協調過程,此時才把交易中不滿意的細節揭露,推文同樣出現大量護航,甚至鄉民bacteria373攻擊嘲諷新人看到毛片失望是「覺得自己要被修的地方太多」,不久遭版主抓包該鄉民一次開多帳號攻擊,IP相同。
https://www.ptt.cc/bbs/GetMarry/M.1629136242.A.BFD.html
7. 下午版友C大回文提供法律解釋,要大家別跟新人一樣被吃豆腐。
「婚紗攝影定型化契約應記載及不得記載事項」中,若無另行規範則:
a.著作人為業者
b.著作財產權人為「消費者」https://www.ptt.cc/bbs/GetMarry/M.1629181390.A.B76.html
8. 當天下午另一版友H大看不過去,回文幫忙整理事件重點,根據攝影師澄清文提供時間點,事發日下午三點,攝影師「第一時間」確實「不當一回事」,也無立即致歉,等新人文章已在網路上有些回應,攝影師才於晚上十點發了長文給新人道歉。https://www.ptt.cc/bbs/GetMarry/M.1629189478.A.9D1.html
攝影師道歉文重點如下:
兩分道歉,三分解釋,剩下一半都是「我好可憐」,行情緒勒索之術。

<八月十九>
9. 另一版友M大回文,揭露於新人發文、代Po攝影師澄清文中的大量攻擊、護航推文為「公關帳號」,過去已有葉佩商品的互推文紀錄,並作圖提供證據。
https://www.ptt.cc/bbs/GetMarry/M.1629319314.A.80E.html
——

至今,攝影師並未做第二次回覆,工作室臉書貼文也是護航滿滿,明明是自己有錯在先,卻行已道歉之名,在PTT上躲在公關帳號背後去攻擊新人,所用帳號數甚多,儼然是花錢的網路霸凌。

一般的良心商家遇到爭議,會誠心道歉,讓風波過去,這間「卡菲小姐 Mr. Kafii」卻不斷找理由,還找網軍帶風向,試圖減輕責任,轉移「未經授權/詢問的第三方商用」焦點,並塑造新人刻意找麻煩的形象。

我自己平常在Dcard也會發文分享,會不會有一天不小心發表了什麼負面心得,同樣遭到網軍出征,只因店家咽不下這口氣?
如果今天放縱了這樣的網路霸凌,是不是會有下一個卡菲小姐,出事就找公關攻擊,難道網路上只能有好評跟恭維,不能接受其他心得嗎?

希望大家高調,遏制網軍霸凌,別讓攝影師得逞。

註:我這篇文章為個人所寫,無受人所託,我也不認識新人,更無收錢之事。
本篇來源:https://www.dcard.tw/f/talk/p/236770720

how to Streaming on chat interface using Gradio? | Gradio + OpenAI Streaming mode

how to Streaming on chat interface using Gradio? | Gradio + OpenAI Streaming mode

OpenAi 官方的Stream教學 https://platform.openai.com/docs/api-reference/chat/streaming
Gradio 官方的Stream教學 https://www.gradio.app/guides/creating-a-custom-chatbot-with-blocks#add-streaming-to-your-chatbot
兩者結合一下就可以完成Stream, 效果如下

How to Bypass CAPTCHA With Selenium & Python

How to Bypass CAPTCHA With Selenium & Python

Cloudflare blocks out threats and bad bots and, unfortunately for us, it also assumes all non-whitelisted bot traffic is malicious. This makes web scraping difficult since there’s a good chance our scraper will be denied access to a Cloudflare-protected web page.

One of the best ways to solve this is by using a headless browser, like Selenium, because it’s capable of imitating the activities of a real user. In this guide, we’ll discuss the most effective method to bypass Cloudflare with Selenium.

Let’s jump right in!

What Is Selenium

Selenium is a Python library used for automating web browsers and scraping web pages. Selenium extensions emulate user interaction and provide interactivity in various ways, like enabling the clicking of buttons, scrolling the page, executing custom JavaScript code, simulating user inputs and so on. It automates processes on several browsers, including Firefox and Chrome, using the Webdriver protocol.

What Is Cloudflare and How Does It Work

Cloudflare is a web performance and security company that works to secure and optimize websites and applications. When it comes to security, Cloudflare offers a Web Application Firewall (WAF) that is capable of defending against web attacks, such as cross-site scripting (XSS) and DDoS attacks.

Does Cloudflare Detect Selenium

Unfortunately for us, Cloudflare Bot Management is capable of detecting Selenium. Cloudflare stops malicious HTTP traffic from moving on to the server and it performs security checks to mitigate Layer 7 (application layer) of DDoS attacks. These security checks would identify a Selenium webDriver as a bot.

On a site running with Cloudflare, an interstitial page comes up for 5 seconds. If the checks on the HTTP traffic pass as genuine, the server redirects the user to the page. If not, the page stays there and shows a CAPTCHA.

How Does Cloudflare Block Bots?

Cloudflare’s bot detection techniques can be classified into two categories: passive and active. Passive bot detection uses backend server detection techniques, like TLS fingerprinting, HTTP request headers and IP address reputation. Active bot detection happens on the client side, including CAPTCHAs, event tracking, canvas fingerprinting and others.

Can Selenium Bypass Cloudflare?

Yes! It’s possible to bypass Cloudflare in Selenium. While using base Selenium might not be enough, it’s possible to install extended Selenium libraries to help you avoid Cloudflare detection.

First, let’s run through a quick example to show you why base Selenium isn’t enough. We’ll be using DataCamp, a website with Cloudflare anti-bot protection.

The following tools are necessary to follow along with this tutorial.

Selenium WebDriver serves as a web automation tool, allowing you to manage web browsers. Previously, you needed to install WebDriver separately, but starting from Selenium version 4 and later, it comes bundled. If you’re using an older version, update to access the latest features and capabilities. Check your current version using pip show selenium and upgrade with pip install --upgrade selenium.

Open a terminal. In your desired directory, install Selenium.

pip install selenium 

In your Python file, copy and paste the code block below.

from selenium import webdriver 
from selenium.webdriver.chrome.options import Options 
import time 
 
options = Options() 
options.add_argument("--headless") # Headless mode

driver = webdriver.Chrome(options=options) 

driver.get("https://www.datacamp.com/users/sign_in") 
 
time.sleep(20) 
 
driver.save_screenshot("datacamp.png") 
 
driver.close()

Run the Python file.

DataCamp Blocked
Click to open the image in full screen

After running the script, the request came back with an error preventing access to the HTML elements, and we can’t crawl the webpage without these elements. Good one, Cloudflare, you win this one!

So how do we tweak Selenium to bypass Cloudflare? We’re getting there.

Frustrated that your web scrapers are blocked once and again?
ZenRows API handles rotating proxies and headless browsers for you.

Try for FREE

How to Bypass Cloudflare with Selenium

As we’ve discussed and shown, using base Selenium for Cloudflare just doesn’t work since it isn’t capable of accessing sites with complex anti-bot services. That said, let’s take a look at a few tweaks and tricks available to bypass Cloudflare Selenium.

Selenium Cloudflare Bypass with undetected_chromedriver

undetected_chromedriver is a selenium.webdriver.Chrome replacement and it’s often used when there’s a need to access a site with anti-bot protection as it focuses on stealth. With undetected_chromedriver, a web-driver can be created and used to bypass bot detections, like Cloudflare.

Let’s proceed to use undetected_chromedriver to access the DataCamp sign-in page. Start by installing it.

pip install undetected-chromedriver

Create a Python file and import undetected_chromedriver.

import undetected_chromedriver as uc

Instantiate undetected_chromedriver.

driver = uc.Chrome(...)

With our instantiated driver, let’s make a successful call to DataCamp using .get() from the webdriver. time.sleep is used as an explicit wait condition to keep our window open until the process is done and the maximize_window() method is used to maximize the window if it’s not already maximized.

import undetected_chromedriver as uc 
import time 
 
options = uc.ChromeOptions() 
options.headless = False  # Set headless to False to run in non-headless mode

driver = uc.Chrome(use_subprocess=True, options=options) 
driver.get("https://www.datacamp.com/users/sign_in") 
driver.maximize_window() 

time.sleep(20) 
driver.save_screenshot("datacamp.png") 
driver.close()

Run the created file using the Python command and the name of the file:

python scraper.py

And that’s it, here’s what you’ll see:

DataCamp Login Page Unblocked
Click to open the image in full screen

Congratulations! You have avoided getting Selenium blocked by Cloudflare, well for now.

Limitations of undetected_chromedriver

If you’re looking to scrape a website with basic anti-bot protection, then undetected_chromedriver might be enough for you. But when it comes to websites that use advanced Cloudflare protection and other DDoS mitigation services, undetected_chromedriver can be unreliable.

For example, we tried to access the Asana page on g2.com using undetected_chromedriver and the steps shared above. Do you want to know what happened? We got blocked.

G2 Blocked
Click to open the image in full screen

As you can see, undetected_chromedriver failed because the G2 anti-bot service detected that our browser session was automated. So how do we solve this problem? Easy: using ZenRows.

Selenium Cloudflare bypass using ZenRows

ZenRows is a web scraping tool capable of bypassing different types of antibots, even complex ones, with a simple API call. And yes, it can bypass Cloudflare without stress. Let’s see how.

Zenrows dashboard
Click to open the image in full screen

To get started, create a free ZenRows account and navigate to the Request Builder. We’ll be using Zenrows API, so click on Python and select API from the options on the screen. Paste the URL to scrape, enable Javascript rendering, and Antibot. ZenRows will automatically generate a Python web scraping script for you.

Copy the code generated and paste it into your Python file.

# pip install requests
import requests

url = 'https://www.g2.com/products/asana/reviews'
apikey = '<YOUR_ZENROWS_API_KEY>'
params = {
    'url': url,
    'apikey': apikey,
    'js_render': 'true',
    'antibot': 'true',
    'premium_proxy': 'true',
}
response = requests.get('https://api.zenrows.com/v1/', params=params)
print(response.text)

The final step is to run the script in the terminal.

python scraper.py

Boom! Just like that, we have our output:

Output
Click to open the image in full screen

C’est fini, you’ve successfully bypassed Cloudflare with ZenRows!

使用 acme.sh 取得 Let’s Encrypt 免費 SSL證書

使用 acme.sh 取得 Let’s Encrypt 免費 SSL證書

安裝 acme.sh
# wget -O – https://get.acme.sh | sh

將 acme.sh 的別名指定到路徑上
# alias acme.sh=~/.acme.sh/acme.sh
(解除:unalias acme.sh )

產生證書
更新:目前 acme.sh 採用 ZeroSSL,首次申請SSL證書時必須要使用email註冊一個帳號
acme.sh –register-account -m Email@gmail.com

單一網域申請證書:
# acme.sh –issue -d 你的網域 -w 網域的根目錄
# acme.sh –issue -d domain.com -w /var/www/html

多個網域申請證書:
# acme.sh –issue -d 你的網域A -d 你的網域B …… -w 網域的根目錄
# acme.sh –issue -d domain.com -d www.domain.com -d dev.domain.com -w /var/www/html

當證書產生完成後,畫面上最後會顯示你的每一個證書所產生的路徑!

Your cert is in /家目錄/.acme.sh/你的網域/你的網域.cer
Your cert key is in /家目錄/.acme.sh/你的網域/你的網域.key
The intermediate CA cert is in /家目錄/.acme.sh/你的網域/ca.cer
And the full chain certs is there: /家目錄/.acme.sh/你的網域/fullchain.cer

由於安裝程序的過程中已經自動設定了 corntab 了 使用 crontabl -l 查看指令

caraz 地墊 城堡 團購超貴,不如直接去韓國Gmarket網購省更多

caraz 地墊 城堡 團購超貴,不如直接去韓國Gmarket網購省更多


(圖片來源 Gmarket)
對於新生爸媽而言,胚胎從有心跳的瞬間,就是個花費的開始。
花費的金額和小孩的年齡成正比,因此爸媽要學會多樣技能以及省錢的技巧!

最近在找寶寶會爬行之後需要的地墊,目前CP值最高的就是韓國的CARAZ這個牌子。
相關介紹網路很多開箱文,本篇我只想介紹最便宜買的方法,開箱不是我的重點因此略過。
可惜CARAZ在台灣買超貴,而網路上團購的價格也是韓國的兩倍以上。

CARAZ在台灣,一片尺寸200*140的地墊,其團購價格是3999元,台灣售價是4999元。
那麼韓國賣多少呢??
答案是:

(截圖來源 Gmarket)
沒錯,價格是2491元,而且這是 買一送一 共兩片!韓國寄過來運費約1200元,
所以總價(2491+1200)/2=1845元/一片!

我們來看看關於城堡這一款。
台灣的團購價是9399元,台灣售價是9999元,那麼韓國賣多少呢?
答案是:

(截圖來源 Gmarket)
沒錯,價格是5549元,韓國寄過來運費約1200元,
所以總價是5549+1200=6749元!

如果你在韓國買地墊,最少可省下4999-1845=3154元
如果你在韓國買城堡,最少可省下9999-6749=3250元

上面的韓國價格都還不包括 每月的Gmarket折價券、國際運費優惠(有時會免運促銷),所以價格都會再更低。
以我自己經驗,首次購物減10000韓元,國際運費2.5折,我買到城堡的總價是6519元!

好的,你會說,可是你在韓國買,寄過來還要等阿,台灣至少有現貨會比較快吧?
很抱歉,無論你是團購還是台灣網站購買,通常也是要等。
以我今天(2017/08/27)發文的例子來說,
台灣網站就沒貨(顯示9月才到貨),那既然都是要等要預購,我幹嘛不直接韓國Gmarket買就好呢?
根據經驗,下單後,約7~10能收到貨物。
這是我這次幫朋友購買的訂單資料:

(截圖來源 Gmarket)

如果你擔心不懂韓文,沒關係,Gmarket現在有完全中文的介面了,購買操作方式跟你買蝦皮露天是一樣的啊!

(截圖來源 Gmarket)

是不是很親切?連商品介紹都寫中文呀(請看上面幾張的地墊和城堡圖片,文字是中文喔)!

接下來教你個小技巧,怎麼在Gmarket找到最便宜的! (如果你懶的話, 最下方我會提供Gmarket的賣場連結)
網站先切到中文介面,然後在搜尋打上 caraz 1+1

(截圖來源 Gmarket)

接著再用價錢排序,按最低價格

(截圖來源 Gmarket)
由於有許多賣家都在賣CARAZ, 有的只有在韓國當地出貨,有的願意出貨到海外,所以要找有飛機圖案的,
表示可以送到海外

(截圖來源 Gmarket)
上圖可以看到,有飛機的CARAZ 買1送1地墊最便宜賣1650元(小片的)!
而且他有中文商品信息,賣家身分又是金冠! 所以就選 카라즈몰 啦!

接下來就是一般網購流程了,這邊我就略過。
其中要注意的是 所以收件/購買人訊息都要打「英文」,手機號碼要記得886,
貨運的話SF(順豐)會比較便宜,EMS是比較貴但有快一點點。

以上是本次心得分享,希望各位爸媽都能買到最超值的育兒商品。
中華郵政地址 中翻英→ https://www.post.gov.tw/post/internet/Postal/index.jsp?ID=207
本次我購買的Gmarket賣場連結在此
聲明:本頁內容圖檔皆來自 http://www.gmarket.co.kr/ 網站截圖。
本頁內容文字為作者個人購買經驗分享,非為營利目的,僅代表作者個人主觀立場。

Ubuntu 20 使用 Anaconda 解決tensorflow gpu 問題

Ubuntu 20 使用 Anaconda 解決tensorflow gpu 問題

簡單作法如下
1.安裝 NVIDIA 官方 driver
2.建立 conda env (TF2.2) 並一併安裝 tensorflow-gpu
這步驟會把 cuda toolkit、 CUDNN 一起安裝
3.啟動 ENV (TF2.2)
4.跑 code

—————
1.安裝 NVIDIA 官方 driver:
清除原有的nvidia driver (如果你有的話)
sudo apt-get purge nvidia*
加入顯卡 ppa
sudo add-apt-repository ppa:graphics-drivers
package 更新
sudo apt-get update
sudo apt upgrade
Unable to lock the administration directory (/var/lib/dpkg/), is another process using it?
找出目前支援的GPU driver 版本
ubuntu-drivers list
安裝 nvidia driver
sudo apt install nvidia-driver-VERSION_NUMBER_HERE
我目前 (2021/7) 使用 460 版本
sudo apt install nvidia-driver-460
安裝完後重啟
sudo reboot
檢查是否安裝成功
nvidia-smi

2.
conda create –name tf python=3.7.5 tensorflow-gpu==2.2.0
conda activate tf

acme.sh 預設 CA 更新為 ZeroSSL 引起的問題

acme.sh 預設 CA 更新為 ZeroSSL 引起的問題

[Mon Jul 12 15:53:31 CST 2021] Using CA: https://acme.zerossl.com/v2/DV90
[Mon Jul 12 15:53:31 CST 2021] No EAB credentials found for ZeroSSL, let’s get one
[Mon Jul 12 15:53:31 CST 2021] acme.sh is using ZeroSSL as default CA now.
[Mon Jul 12 15:53:31 CST 2021] Please update your account with an email address first.
[Mon Jul 12 15:53:31 CST 2021] acme.sh –register-account -m my@example.com
[Mon Jul 12 15:53:31 CST 2021] See: https://github.com/acmesh-official/acme.sh/wiki/ZeroSSL.com-CA
[Mon Jul 12 15:53:31 CST 2021] Please add ‘–debug’ or ‘–log’ to check more details.
[Mon Jul 12 15:53:31 CST 2021] See: https://github.com/acmesh-official/acme.sh/wiki/How-to-debug-acme.sh
Error: Create Let’s Encrypt SSL Certificate failed!

因為預設使用ZeroSSL 需要先註冊,改回使用Let’s Encrypt,使用指令:

# .acme.sh/acme.sh –set-default-ca –server letsencrypt

Done!

[更新]

acme.sh –set-default-ca –server letsencrypt
↑改為預設letsencrypt

/dev/mapper/VolGroup-lv_root爆滿 調整大小

/dev/mapper/VolGroup-lv_root爆滿 調整大小

目標:將VolGroup-lv_home縮小到20G,並將剩余的空間添加給VolGroup-lv_root

1.首先查看磁盤使用情況

[[root@localhost ~]# df -h
文件系統 容量 已用 可用 已用% 掛載點
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/VolGroup-lv_root 154G 7.9G 139G 6% /
tmpfs 1.9G 100K 1.9G 1% /dev/shm
/dev/sda1 485M 69M 391M 15% /boot
/dev/mapper/VolGroup-lv_home 299G 984M 283G 1% /home
2、卸載/home

[root@localhost ~]# umount /home
umount /home 如果提示無法卸載
[root@localhost ~]# umount –lf /home 強制卸載
-f:強制卸載
-l:清除與文件系統相關的引用
3、調整分區大小

[root@localhost ~]# resize2fs -p /dev/mapper/VolGroup-lv_home 20G
如果提示運行“e2fsck -f /dev/mapper/VolGroup-lv_home”,則執行相關命令:
[root@localhost ~]# e2fsck -f /dev/mapper/VolGroup-lv_home 然後重新執行命令:
[root@localhost ~]# resize2fs -p /dev/mapper/VolGroup-lv_home 20G
註:resize2fs 為重新設定磁盤大小,只是重新指定一下大小,並不對結果有影響,需要下面lvreduce的配合

4、掛載上/home,查看磁盤使用情況

[root@localhost ~]# mount /home
[root@localhost ~]# df -h
5、設置空閑空間
使用lvreduce指令用於減少LVM邏輯卷占用的空間大小。可能會刪除邏輯卷上已有的數據,所以在操作前必須進行確認。記得輸入 “y”
[root@localhost ~]# lvreduce -L 20G /dev/mapper/VolGroup-lv_home
註:lvreduce -L 20G的意思為設置當前文件系統為20G,如果lvreduce -l 20G是指從當前文件系統上減少20G
使用lvreduce減小邏輯卷的大小。註意:減小後的大小不能小於文件的大小,否則會丟失數據。

可以使用vgdisplay命令等查看一下可以操作的大小。也可以是用fdisk -l命令查看詳細信息。
[root@localhost ~]# vgdisplay
註:vgdisplay為顯示LVM卷組的元數據信息

6.把閑置空間掛在到根目錄下

[root@localhost ~]# lvextend -L +283G /dev/mapper/VolGroup-lv_root
註:lvextend -L +283G為在文件系統上增加283G
[root@localhost ~]# resize2fs -p /dev/mapper/VolGroup-lv_root
7、檢查調整結果
[root@localhost ~]# df -h

增加新磁盤對VolGroup-lv_root進行擴容
前面提到過/dev/mapper/VolGroup-lv_root是一個邏輯卷,既然是邏輯卷那麽就可以給它的卷組(資源池)進行擴容。

[root@localhost ~]# df -h
文件系統 容量 已用 可用 已用%% 掛載點
/dev/mapper/VolGroup-lv_root
18G 1.2G 16G 7% /
tmpfs 495M 0 495M 0% /dev/shm
/dev/sda1 485M 32M 428M 7% /boot
/dev/sdb1 8.9G 149M 8.3G 2% /home

CentOS FTP 更換Port後 無法連線

CentOS FTP 更換Port後 無法連線

原本VSFTP使用21PORT,後來需改成其他端口,改了listen的port後,卻連不上了。
但iptables關掉就能連上,猜測應該是iptables在擋。

解決方法:使用PASV模式
/etc/vsftpd/vsftpd.conf
增加下面三行
pasv_enable=Yes
pasv_max_port=10100
pasv_min_port=10090

/etc/sysconfig/iptables
增加下面一行
-A INPUT -p tcp –destination-port 10090:10100 -j ACCEPT

重啟vsFTP跟iptables

之後從新的port連線,成功!