Can anyone access pluggable-transports/meek.git? - tor

git clone https://git.torproject.org/pluggable-transports/meek.git
fatal: unable to access 'https://git.torproject.org/pluggable-transports/meek.git/': Failed to connect to gitweb.torproject.org port 443: Connection timed out
and I get TorBrowser running ,and config git with
git config --global http.proxy 'socks5://127.0.0.1:9150'
git config --global https.proxy 'socks5://127.0.0.1:9150'
and git clone get these message:
fatal: unable to access 'https://git.torproject.org/pluggable-transports/meek.git/': Can't complete SOCKS5 connection to 0.0.0.0:0. (1)
Does meek source code accessible?
I want use tor not JUST TorBrowser Bundle . and I need meek to get out the GFW .
curl https://torproject.org --socks5 '127.0.0.1:9150'
curl: (7) Can't complete SOCKS5 connection to 0.0.0.0:0. (6)
TorBrowser 6.0.6 is running
ScreenShot

The apparent problem is that Git's HTTP(S) proxy doesn't do DNS resolution over SOCKS and relies on your system DNS server. So when you try to clone (via https://gitweb.torproject or the .onion site) it's doing a DNS lookup through your default DNS servers which I think are giving you bad information.
This should work (because it resolves DNS over Tor):
curl https://torproject.org --socks5-hostname '127.0.0.1:9150'
While this probably doesn't (because it uses your default DNS servers):
curl https://torproject.org --socks5 '127.0.0.1:9150'
That said, I didn't try very hard or look more into having Git's proxy resolve DNS over SOCKS, but the easier thing to do is try using torsocks or proxychains.
Go to https://github.com/rofl0r/proxychains-ng - download, configure, build, and install. Then edit /etc/proxychains.conf and change socks4 127.0.0.1 9050 to socks5 127.0.0.1 9150
Then run:
./proxychains4 git clone http://dccbbv6cooddgcrq.onion/pluggabletransports/meek.git
If it works, you're set.
The directory permissions are fine. They show up funny in the web viewer d--------- but when you clone it, the directories will get permissions (probably 0755) based on your umask.
In any case, if you're still stuck, I've uploaded the meek git clone to https://drew.co.il/downloads/meek.zip so you can try to download that. It'll have the .git directory in it in case you need that later.

I checked meek source tree ,and find out it has d--------- permission . There is no 'w',nor 'x' and no 'r' ,but yet ,the directory can be accessed from browser ,and its file has 644 permission . Perhaps that's why i cann't clone it .
BTW,TBB's proxy works fine . and git's proxy configuration also right . If anyone else wants to know .

Related

Git clone gives "ssh: connect to host github.com port 22: Connection timed out" Linux /opt directory Amazon EC2 Instance

Issue
I am trying to use git in /opt/jamf2snipe directory on an EC2 Instance. I have tried the following command:
sudo git clone git#github.com:MYUSERNAME/jamf2snipe-school.git
It says connection timed out:
Cloning into 'jamf2snipe-school'...
ssh: connect to host github.com port 22: Connection timed out
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
If I try to run this in my home directory it works fine. It seems to be a permission issue with /opt. I am wary of changing permissions for /opt.
Setup
I am trying to do this on an Amazon EC2 Instance. Currently SSH is limited to certain IP addresses (not including Github). I followed this article from github to use SSH over HTTPS. I tested to make sure I had stuff setup correctly by using:
$ ssh -T git#github.com
received
Hi USERNAME! You've successfully authenticated, but GitHub does not provide shell access.
I did this in /opt/jamf2snipe and the home directory successfully.
First, make sure to, if possible, not use sudo.
In addition of executing commands as root (which is dangerous), it uses its own environment variable, and SSH settings (in /root/.ssh), which differs from your normal EC2 user.
Conversely, making a repository in /opt, which might be accessible only by root, is not the best spot to clone a repository.
Second, Using SSH over the HTTPS port is the usual solution (like this one from 2018) on EC2, where the firewall can block by default SSH egress traffic.

git clone from internal gitlab repository doesn't work unless I'm running as root

I'm trying to clone an internal gitlab repository, but it keeps giving me this error message
fatal: unable to access 'https://gitlab**************.git/': gnutls_handshake() failed: Error in the pull function.
But somehow, if I'm running as root, the cloning process would run perfectly.
The problem is, I needed this to work because I'm trying to use this repository on Jenkins.
Can someone help me or explain why it only worked if I'm running as root?
root uses the same version of git and curl.
But it does not use the same:
global git config: compare the output of git config --global -l in both instances (root and regular user account).
environment configuration (type env in both cases, and compare the environment variables)
In particular, look for sslcainfo (git config --global -l|grep -i ssl) which could reference the certificate needed to contact through TLS your on-premise HTTPS GitLab URL.

ssh: Could not resolve hostname github.com: Temporary failure in name resolution

The repo was cloned using SSH at the start. I had no issues pushing to Github until today. I've been trying to solve this error for a whole day but i still cannot solve this error.. It would be great if anyone can shed some light on this! Thank you :)
2dsnakegame git:(main) git push origin main
ssh: Could not resolve hostname github.com: Temporary failure in name resolution
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
➜ 2dsnakegame git:(main) git remote
origin
➜ 2dsnakegame git:(main) git remote --v
origin git#github.com:xxxx/2dsnakegame.git (fetch)
origin git#github.com:xxxx/2dsnakegame.git (push)
I had the same situation working on Windows with WSL2. It looks like there was a trouble on the connection to the DNS server, so I basically reset my TCP/IP with the following commands and then git pull/git push worked again.
From University of Wisconsin: Windows 10 TCP/IP Reset: Open the cmd prompt on Windows as an administrator and run the following commands in this order in order to fix your connection problem:
netsh winsock reset
netsh int ip reset
ipconfig /release
ipconfig /renew
ipconfig /flushdns
Finally, restart your computer.

git clone fatal error - repository 'https' does not exist

I am trying to get a git clone of a github repo, namely odoo (formerly OpenERP). When trying to run the git clone command in Centos 8, I get the following error:
error as shown in terminal
I am running this command in root. I have tried running it as sudo.
The machine is running in a VPS, and seems to have https resolving issues. I can't ping google through https for instance. I also checked, and there is no firewall causing issues. https ping attempt
How do I best approach this? I'm not sure if it is a name server issue or the like.
Try git clone https://github.com/odoo/odoo.git --depth 1 -b 13.0
Ping requires only hostname, not a URL. Try pinging ping google.com

Jenkins Error 128 / Git Error 403: Jenkins can't connect to my Bitbucket repository

OS: Ubuntu 16.04
Hypervisor: VirtualBox
Network configuration: Nat Network with port forwarding to access the vms through the host ip. I can also ping a VM from another VM.
I try to connect my Jenkins app hosted on a VM to my BitBucket server also on a VM. I followed a tutorial on internet but when i enter the address of my git repository i'm getting this:
Failed to connect to repository : Command "usr/bin/git ls-remote -h http://admin#192.168.6.102:8005/scm/tes/repository-test.git HEAD" returned status code 128:
stdout:
stderr: fatal: unable to access 'http://admin#192.168.6.102:8005/scm/tes/repository-test.git/': The requested URL returned error: 403
So, to be sure I tried to exectute the command on the terminal... and on the terminal it seems to work.. I can also push, clone, pull etc..
On this image you can see that it's true
Do you have an explanation?
EDIT:
I try some others things like use or not sudo to see if the permissions problem came from that and it seems that it's not the case.
But I see that there is no result when we use the "HEAD" argument.
Do you think that because "HEAD" give no result, git in jenkins interprets it like no answer and returns the damn** error 403?
EDIT 2:
I found that on the web: http: // jenkins-ci.361315.n4.nabble.com/Jenkins-GIT-ls-remote-error-td4646903.html
The guy has the same problem but in a different way, I will try to allocate more RAM to see if it does the trick.
There could be many possible problems, but you are getting 403 - Access Forbidden, which indicates some problem with permissions. I would suggest first common mistakes:
a) trying https instead http - my scm only uses https,
b) check if admin is correct - scm by default uses scmadmin.
Here I run the exact same command twice.
The first time I used the proxy configuration wich I need to access internet, and the second time I set the mandatory server on "none".
So there is a problem with the damn proxy.
I was thinking that the proxy was not used in NAT connection with VirtualBox...
I found the solution.
I had to reinstall jenkins to have a user named "jenkins" with his own home directory.
I don't know if it is linked or not, but I configured my bitbucket server to use only HTTPS with a self signed certificate (I work in lan)
My troubleshoot was linked with my proxy settings.
I disabled all my proxy settings in Linux so I was able to launch the command that did'nt worked in jenkins with terminal.
I logged with sudo su jenkins the commands also worked.
I found out that in the home directory of the jenkins user there was a "proxy.xml" file. I opened it and saw my old proxy settings.
I deleted all the content with vim, saved and restarted and the error was gone.
there can be git version miss match.....
I would suggest you update git once. maybe it will resolve your issues.

Resources