[Git][codeigniterpower/codeigniterpower][master] 2 commits: Bug Fix: [cookie_helper.php] set_cookie was missing sameSite argument

0 views
Skip to first unread message

Герхард PICCORO Lenz McKAY (@mckaygerhard)

unread,
Feb 5, 2024, 7:40:02 AMFeb 5
to venenux...@googlegroups.com

Герхард PICCORO Lenz McKAY pushed to branch master at codeigniterpower / codeigniterpower

Commits:

  • f4f90097
    by Mouad Err at 2024-02-05T08:33:36-04:00
    Bug Fix: [cookie_helper.php] set_cookie was missing sameSite argument
    
  • d28e3e34
    by László Bóra at 2024-02-05T08:40:13-04:00
    fixes #6149
    remove deprecated variable variables / string interpolation in variable names
    

4 changed files:

Changes:

  • appsys/database/DB_query_builder.php
    ... ... @@ -699,11 +699,11 @@ abstract class CI_DB_query_builder extends CI_DB_driver {
    699 699
     				$k = substr($k, 0, $match[0][1]).($match[1][0] === '=' ? ' IS NULL' : ' IS NOT NULL');
    
    700 700
     			}
    
    701 701
     
    
    702
    -			${$qb_key} = array('condition' => $prefix.$k, 'value' => $v, 'escape' => $escape);
    
    703
    -			$this->{$qb_key}[] = ${$qb_key};
    
    702
    +			$$qb_key = array('condition' => $prefix.$k, 'value' => $v, 'escape' => $escape);
    
    703
    +			$this->{$qb_key}[] = $$qb_key;
    
    704 704
     			if ($this->qb_caching === TRUE)
    
    705 705
     			{
    
    706
    -				$this->{$qb_cache_key}[] = ${$qb_key};
    
    706
    +				$this->{$qb_cache_key}[] = $$qb_key;
    
    707 707
     				$this->qb_cache_exists[] = substr($qb_key, 3);
    
    708 708
     			}
    
    709 709
     
    

  • appsys/helpers/cookie_helper.php
    ... ... @@ -68,10 +68,10 @@ if ( ! function_exists('set_cookie'))
    68 68
     	 * @param	bool	true makes the cookie accessible via http(s) only (no javascript)
    
    69 69
     	 * @return	void
    
    70 70
     	 */
    
    71
    -	function set_cookie($name, $value = '', $expire = '', $domain = '', $path = '/', $prefix = '', $secure = NULL, $httponly = NULL)
    
    71
    +	function set_cookie($name, $value = '', $expire = 0, $domain = '', $path = '/', $prefix = '', $secure = NULL, $httponly = NULL, $samesite = NULL)
    
    72 72
     	{
    
    73 73
     		// Set the config file options
    
    74
    -		get_instance()->input->set_cookie($name, $value, $expire, $domain, $path, $prefix, $secure, $httponly);
    
    74
    +		get_instance()->input->set_cookie($name, $value, $expire, $domain, $path, $prefix, $secure, $httponly, $samesite);
    
    75 75
     	}
    
    76 76
     }
    
    77 77
     
    

  • appsys/libraries/Xmlrpc.php
    ... ... @@ -1721,7 +1721,7 @@ class XML_RPC_Values extends CI_Xmlrpc
    1721 1721
     
    
    1722 1722
     		if ($typeof != 1)
    
    1723 1723
     		{
    
    1724
    -			echo '<strong>XML_RPC_Values</strong>: not a scalar type (${typeof})<br />';
    
    1724
    +			echo "<strong>XML_RPC_Values</strong>: not a scalar type ($typeof)<br />";
    
    1725 1725
     			return 0;
    
    1726 1726
     		}
    
    1727 1727
     
    

  • appsys/libraries/Xmlrpcs.php
    ... ... @@ -551,8 +551,8 @@ class CI_Xmlrpcs extends CI_Xmlrpc {
    551 551
     	 */
    
    552 552
     	public function multicall_error($err)
    
    553 553
     	{
    
    554
    -		$str = is_string($err) ? $this->xmlrpcstr["multicall_${err}"] : $err->faultString();
    
    555
    -		$code = is_string($err) ? $this->xmlrpcerr["multicall_${err}"] : $err->faultCode();
    
    554
    +		$str = is_string($err) ? $this->xmlrpcstr["multicall_$err"] : $err->faultString();
    
    555
    +		$code = is_string($err) ? $this->xmlrpcerr["multicall_$err"] : $err->faultCode();
    
    556 556
     
    
    557 557
     		$struct['faultCode'] = new XML_RPC_Values($code, 'int');
    
    558 558
     		$struct['faultString'] = new XML_RPC_Values($str, 'string');
    


View it on GitLab.
You're receiving this email because of your account on gitlab.com. Manage all notifications · Help

Reply all
Reply to author
Forward
0 new messages